Skip to content

Commit

Permalink
Update CURLOPT_SSL_VERIFYHOST
Browse files Browse the repository at this point in the history
- CURLOPT_SSL_VERIFYHOST no longer accepts the value 1 (true), and
  hasn't for a whileTM.
- value 2 was being implicity used instead.
- This change reduces PHP Notices in the error log.
  • Loading branch information
gregcorbett committed Oct 12, 2023
1 parent 1fa08cf commit 2b7b2f3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion htdocs/web_portal/GOCDB_monitor/tests.php
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ function get_https2($url)
CURLOPT_FOLLOWLOCATION => false,
CURLOPT_MAXREDIRS => 0,
// VERIFYHOST checks that the CN in the certificate matches what we asked for
CURLOPT_SSL_VERIFYHOST => true,
CURLOPT_SSL_VERIFYHOST => 2,
// VERIFYPEER checks that we trust the certificate's issuer (CA)
// If you are testing with a self-signed host certificate, you will have to
// copy the host's .pem certificate into CURLOPT_CAPATH or
Expand Down

0 comments on commit 2b7b2f3

Please sign in to comment.