diff -ruN phpki.old/phpki-0.82/include/openssl_functions.php phpki/phpki-0.82/include/openssl_functions.php --- phpki.old/phpki-0.82/include/openssl_functions.php 2018-11-17 14:06:06.551603435 +0100 +++ phpki/phpki-0.82/include/openssl_functions.php 2018-11-17 14:07:21.651270471 +0100 @@ -801,31 +801,31 @@ $certtext = CA_cert_text($serial); #if (ereg('OpenSSL.* (E.?mail|Personal) .*Certificate', $certtext) && ereg('Code Signing', $certtest)) { - if (preg_match('OpenSSL.* (E.?mail|Personal) .*Certificate', $certtext) && preg_match('Code Signing', $certtest)) { + if (preg_match('~OpenSSL.* (E.?mail|Personal) .*Certificate~', $certtext) && preg_match('~Code Signing~', $certtest)) { $cert_type = 'email_codesigning'; } #if (ereg('OpenSSL.* (E.?mail|Personal) .*Certificate', $certtext)) { - if (preg_match('OpenSSL.* (E.?mail|Personal) .*Certificate', $certtext)) { + if (preg_match('~OpenSSL.* (E.?mail|Personal) .*Certificate~', $certtext)) { $cert_type = 'email'; } #elseif (ereg('OpenSSL.* Server .*Certificate', $certtext)) { - elseif (preg_match('OpenSSL.* Server .*Certificate', $certtext)) { + elseif (preg_match('~OpenSSL.* Server .*Certificate~', $certtext)) { $cert_type = 'server'; } #elseif (ereg('timeStamping|Time Stamping', $certtext)) { - elseif (preg_match('timeStamping|Time Stamping', $certtext)) { + elseif (preg_match('~timeStamping|Time Stamping~', $certtext)) { $cert_type = 'time_stamping'; } #elseif (ereg('TLS Web Client Authentication', $certtext) && ereg('TLS Web Server Authentication', $certtext)) { - elseif (preg_match('TLS Web Client Authentication', $certtext) && preg_match('TLS Web Server Authentication', $certtext)) { + elseif (preg_match('~TLS Web Client Authentication~', $certtext) && preg_match('~TLS Web Server Authentication~', $certtext)) { $cert_type = 'vpn_client_server'; } #elseif (ereg('TLS Web Client Authentication', $certtext)) { - elseif (preg_match('TLS Web Client Authentication', $certtext)) { + elseif (preg_match('~TLS Web Client Authentication~', $certtext)) { $cert_type = 'vpn_client'; } #elseif (ereg('TLS Web Server Authentication', $certtext)) { - elseif (preg_match('TLS Web Server Authentication', $certtext)) { + elseif (preg_match('~TLS Web Server Authentication~', $certtext)) { $cert_type = 'vpn_server'; } else {