NYCPHP Meetup

NYPHP.org

[nycphp-talk] Working with openssl

Rob Marscher rmarscher at beaffinitive.com
Thu Aug 17 15:21:10 EDT 2006


Aaron,
Your test page worked for me... you need to include "-----BEGIN RSA 
PRIVATE KEY-----" and "-----END RSA PRIVATE KEY-----" as well as the 
data and don't have any whitespace or linebreaks after "-----END RSA 
PRIVATE KEY-----"

-Rob

Aaron Fischer wrote:
> csnyder wrote:
>> Hmmmmm, indeed. It works for me... perhaps something else is wrong?
>>
>> Demo: http://dey.fcny.org:4242/www-test/openSSLDemo.php
>> Test: http://dey.fcny.org:4242/www-test/ssltest.php
>>
> 
> It does?  I visited those pages, ran it and got the same error:
> 
> Warning: openssl_private_decrypt() [function.openssl-private-decrypt]: 
> key parameter is not a valid private key in 
> /home/csnyder/projects/test/openSSL.php on line 115
> 
> Warning: openssl_free_key() expects parameter 1 to be resource, null 
> given in /home/csnyder/projects/test/openSSL.php on line 118
> 
> -Aaron
> _______________________________________________
> New York PHP Community Talk Mailing List
> http://lists.nyphp.org/mailman/listinfo/talk
> 
> NYPHPCon 2006 Presentations Online
> http://www.nyphpcon.com
> 
> Show Your Participation in New York PHP
> http://www.nyphp.org/show_participation.php
> 



More information about the talk mailing list