[PHP] PHP OpenSSL - Problem with openssl_pkcs7_verify
Hello, I'm having some trouble trying to put the openssl_pkcs7_verify function to work. I have a file signed with a valid certificate with this software: http://www.signfiles.com/p7s-signer/ http://www.signfiles.com/p7s-signer/ What I'm trying to achieve is to extract the contents of the signed file inside PHP. This is what I've got looking to php.net documentation: $path = fullpath/filename.p7s; $results = openssl_pkcs7_verify($path, 0); //$results = openssl_pkcs7_verify($path, PKCS7_BINARY); same problem //$results = openssl_pkcs7_verify($path, PKCS7_TEXT); same problem echo Verification results: . $results; while ($msg = openssl_error_string()) { echo \n . $msg; } When I execute this piece of script the following output is echoed: Verification results: -1 error:02001003:system library:fopen:No such process error:2006D080:BIO routines:BIO_new_file:no such file error:0B084002:x509 certificate routines:X509_load_cert_crl_file:system lib error:0B065068:x509 certificate routines:BY_FILE_CTRL:loading defaults error:0D0D20CC:asn1 encoding routines:SMIME_read_ASN1:no content type This is the php -version output: PHP 5.4.5 (cli) (built: Jul 18 2012 22:25:51) Copyright (c) 1997-2012 The PHP Group Zend Engine v2.4.0, Copyright (c) 1998-2012 Zend Technologies I'm on Windows 7 64 bits operating system, the binary is the latest stable build available today on php.net. Could someone please suggest what else can I try? Tried to google SMIME_read_ASN1:no content type but nothing so far. Regards, Samuel.
Re: [PHP] Re: [PHP-WEBMASTER] Re: [PHP] The Cat Signal
On Fri, July 20, 2012 10:04, Lester Caine wrote: In Europe VAT is applied even on on-line sales. It is the likes of Amazon shipping bulk stock from overseas 'clients' into European warehouses and then supplying them without VAT added directly in Europe that is the problem! How can I compete with someone who is also giving next day delivery, but 20% cheaper ... American sellers are one of the problems here. It depends, because in Europe (I live in Germany), VAT is only added if the value + shiping exceeds 25 Euro and customs are only added, if the value exceeds 150 Euro It does NOT discriminate American sellers, because German sellers have to bill the VAT too Also I buy regulary in the USA and even with heavy USPS costs plus Import-VAT I am mostly lesser expensive as if I buy in Germany... Greetings -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php