Mar 02

Allowing self-signed certificates for pfsockopen and fsockopen

This is more of a personal note. I’m kinda busy, I’ll write more next time perhaps. Use this if you want to connect to HTTPS that is self-signed SSL certificates.

$context = stream_context_create();
stream_context_set_option($context, "ssl", "allow_self_signed", true);
stream_context_set_option($context, "ssl", "verify_peer", false);

This is for placing in front of pfsockopen and fsockopen.

Possibly related:

  1. How to prepend zeroes in front of numbers
  2. Today is the most amazing day
  3. jQuery’s getJSON failing randomly in Internet Explorer
  4. Any Prolog experts around?

No comments yet. Leave yours here.


WordPress powered and Django inspired.
Love and elephants come after.
RSS: Posts and comments.