1
0
mirror of https://github.com/php/php-src.git synced 2026-04-27 18:23:26 +02:00

Downgrade server security level in security level test

We want to test the client side error here, so make sure the
server side can start up successfully.
This commit is contained in:
Nikita Popov
2020-06-18 15:54:02 +02:00
parent c7fe71c8b7
commit 8ba0624a09
+4 -1
View File
@@ -21,7 +21,10 @@ $serverCode = <<<'CODE'
$serverUri = "ssl://127.0.0.1:64322";
$serverFlags = STREAM_SERVER_BIND | STREAM_SERVER_LISTEN;
$serverCtx = stream_context_create(['ssl' => [
'local_cert' => '%s'
'local_cert' => '%s',
// Make sure the server side starts up successfully if the default security level is
// higher. We want to test the error at the client side.
'security_level' => 1,
]]);
$server = stream_socket_server($serverUri, $errno, $errstr, $serverFlags, $serverCtx);