From: brubla at seznam dot cz Operating system: Windows Vista PHP version: 5.2.11 PHP Bug Type: OpenSSL related Bug description: openssl_pkcs7_verify error:0D06B08E
Description: ------------ When message.eml contains row longer than 76 characters, it generates error. message.eml example: Content-Type: application/x-pkcs7-mime; name=smime.p7m; smime-type=signed-data Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="smime.p7m" Content-Description: S/MIME Cryptographic Signed Data MIAGCSqGSIb3DQEHAqCAMIACAQExCzAJBgUrDgMCGgUAMIAGCSqGSIb3DQEHAaCAJIAEggPoQ29u ... AJLxjYfEXR/ltNihtpCr9LQLxH02OBbE8YuhZuOpOeZ6mf+yqgD2AnFuEV0pdX8GTHY+KTe56yzU 2DnMC/2+kWQxs0wz+z/EEluGH+MEIplh1UFiLc/zn6DHbzBORTZNWd94aJzHFyQw50RK3hAw3uLjAAAA AAAA If the last row is fixed: 2DnMC/2+kWQxs0wz+z/EEluGH+MEIplh1UFiLc/zn6DHbzBORTZNWd94aJzHFyQw50RK3hAw3uLj AAAA AAAA everything is ok. Maybe not an error because message is against RFC 2045 which specifies base64 76 character row. But messages like this exists and at least good to mention it in documentation. Reproduce code: --------------- openssl_pkcs7_verify( 'message.eml' PKCS7_NOVERIFY, 'certificate.pem', array('some_ca_certficates') 'some_ca_certficate', 'content.eml' ); Actual result: -------------- openssl_error_string() returns: error:0D06B08E:asn1 encoding routines:ASN1_D2I_READ_BIO:not enough data error:21078082:PKCS7 routines:B64_READ_PKCS7:decode error error:2107A08B:PKCS7 routines:SMIME_read_PKCS7:pkcs7 parse error -- Edit bug report at http://bugs.php.net/?id=50482&edit=1 -- Try a snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=50482&r=trysnapshot52 Try a snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=50482&r=trysnapshot53 Try a snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=50482&r=trysnapshot60 Fixed in SVN: http://bugs.php.net/fix.php?id=50482&r=fixed Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=50482&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=50482&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=50482&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=50482&r=needscript Try newer version: http://bugs.php.net/fix.php?id=50482&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=50482&r=support Expected behavior: http://bugs.php.net/fix.php?id=50482&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=50482&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=50482&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=50482&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=50482&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=50482&r=dst IIS Stability: http://bugs.php.net/fix.php?id=50482&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=50482&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=50482&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=50482&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=50482&r=mysqlcfg