OpenSSL extension for PHP in Ubuntu?
I'm not sure how to recompile PHP with OpenSSL? I've been looking around the OpenSSL PHP page and the OpenSSL tutorials but I don't see any openssl.so
or php-openssl.so
around my server?
Is there a simple package on apt-get
channel so I can install it from there?
I just need to recompile PHP with OpenSSL, but I have no idea how to do this.
EDIT: I run a dedicated server and it's Ubuntu 11.10.
Solution 1:
For a while PHP has had ssl support compliled into it. No extra modules are needed. Check with phpinfo()
. E.g., on Ubuntu 10.04:
$ echo '<?php phpinfo(); ?>' | php 2>&1 |grep -i ssl
Registered Stream Socket Transports => tcp, udp, unix, udg, ssl, sslv3, sslv2, tls
SSL => Yes
SSL Version => OpenSSL/0.9.8k
openssl
OpenSSL support => enabled
OpenSSL Library Version => OpenSSL 0.9.8k 25 Mar 2009
OpenSSL Header Version => OpenSSL 0.9.8k 25 Mar 2009
OpenSSL support => enabled