Skip to content

Commit 35c8f3a

Browse files
committed
Add stream context
1 parent 812d118 commit 35c8f3a

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

src/OCSP/Ocsp.php

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,14 @@ static function getCertificate( $certificate, $issuerCertificate = null )
109109
: CertificateLoader::ensureDer( $issuerCertificate )
110110
)
111111
: ( $urlOfIssuerCertificate
112-
? file_get_contents( $urlOfIssuerCertificate )
112+
? file_get_contents( $urlOfIssuerCertificate, false, stream_context_create( array(
113+
"ssl"=>array(
114+
"verify_peer"=>false,
115+
"verify_peer_name"=>false,
116+
),
117+
)
118+
)
119+
)
113120
: ''
114121
);
115122
$issuerBytes = CertificateLoader::ensureDer( $issuerBytes );

0 commit comments

Comments
 (0)