Closed rodrigo-garcia-engrande closed 6 years ago
At this moment not. But I'd love to have this feature. Since I already foresaw that secure streams require configuration, I created the SecureConnectionOptions
class. It allows to add your suggestions. Are you able to create a PR for this?
Not know, but as soon as i am able will do. Thanks.
Ok, if I find time, I will fix this. Thanks for the suggestion.
PR #49 fixes this issue. In order to create a secure connection with extra stream context options, you cannot use the client factory but you will have to setup a connection instance yourself.
$client = new Client(
new SecureConnection(
'host',
465,
new SecureConnectionOptions(
STREAM_CRYPTO_METHOD_TLSv1_2_CLIENT,
10,
['verify_peer' => false]
)
)
);
I do not see a way to add custom context stream options, for example verify_peer, verify_peer_name and allow_self_signed Is it possible?