File tree Expand file tree Collapse file tree 1 file changed +14
-10
lines changed Expand file tree Collapse file tree 1 file changed +14
-10
lines changed Original file line number Diff line number Diff line change @@ -835,21 +835,25 @@ protected function handleSelfUpdate()
835
835
836
836
print 'Updating the PHPUnit PHAR ... ' ;
837
837
838
+ $ options = array (
839
+ 'ssl ' => array (
840
+ 'allow_self_signed ' => false ,
841
+ 'cafile ' => $ caFile ,
842
+ 'verify_peer ' => true
843
+ )
844
+ );
845
+
846
+ if (PHP_VERSION_ID < 50600 ) {
847
+ $ options ['ssl ' ]['CN_match ' ] = 'phar.phpunit.de ' ;
848
+ $ options ['ssl ' ]['SNI_server_name ' ] = 'phar.phpunit.de ' ;
849
+ }
850
+
838
851
file_put_contents (
839
852
$ tempFilename ,
840
853
file_get_contents (
841
854
$ remoteFilename ,
842
855
false ,
843
- stream_context_create (
844
- array (
845
- 'ssl ' => array (
846
- 'CN_match ' => 'phar.phpunit.de ' ,
847
- 'allow_self_signed ' => false ,
848
- 'cafile ' => $ caFile ,
849
- 'verify_peer ' => true
850
- )
851
- )
852
- )
856
+ stream_context_create ($ options )
853
857
)
854
858
);
855
859
You can’t perform that action at this time.
0 commit comments