Skip to content

Instantly share code, notes, and snippets.

Created March 17, 2016 10:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save anonymous/94b232357aa71e2b8e3f to your computer and use it in GitHub Desktop.
Save anonymous/94b232357aa71e2b8e3f to your computer and use it in GitHub Desktop.
<?php
//echo dirname(__FILE__);
$curl = curl_init('https://mydomain.com/');
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_NOBODY, true);
curl_setopt($curl, CURLOPT_CERTINFO, true);
curl_setopt($curl, CURLOPT_VERBOSE, 1);
curl_exec($curl);
$certInfo = curl_getinfo($curl, CURLINFO_CERTINFO);
var_dump($certInfo);exit;
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment