This repository was archived by the owner on Jan 30, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 86
About the ssltransport option for the Socket client #105
Comments
@mlocati this proposal can represent an improvement but it's a big BC break. Especially if we set TLS as default. We should find a different proposal without BC break, to support the new protocols including the options included in PHP 5.6. |
We could add new values to protected static $sslCryptoTypes = [
// Current values (deprecated)
'ssl' => STREAM_CRYPTO_METHOD_SSLv23_CLIENT,
'sslv2' => STREAM_CRYPTO_METHOD_SSLv2_CLIENT,
'sslv3' => STREAM_CRYPTO_METHOD_SSLv3_CLIENT,
'tls' => STREAM_CRYPTO_METHOD_TLS_CLIENT,
// New values
'SSL' => 'SSL', // Enable SSL v2 v3
'SSLv2' => 'SSLv2', // Enable SSL v2 only
'SSLv3' => 'SSLv3', // Enable SSL v3 only
'TLS' => 'TLS', // Enable TLS v1.0 and v1.1 and v1.2
'TLSv1.0' => 'TLSv1.0', // Enable only TLS v1.0 only
'TLSv1.1' => 'TLSv1.1', // Enable only TLS v1.2 only
'TLSv1.2' => 'TLSv1.2', // Enable TLS v1.2 only
'*' => '*', // Enable any kind of connection
]; |
I'd suggest NOT including any ssl versions in the new values. |
I'd disagree: we all know that SSL should be avoided, but we can't assume that nobody uses/needs it... |
This repository has been closed and moved to laminas/laminas-http; a new issue has been opened at laminas/laminas-http#7. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
We currently accept these values for the
ssltransport
option of the Socket client:ssl
⇒STREAM_CRYPTO_METHOD_SSLv23_CLIENT
sslv2
⇒STREAM_CRYPTO_METHOD_SSLv2_CLIENT
sslv3
⇒STREAM_CRYPTO_METHOD_SSLv3_CLIENT
tls
⇒STREAM_CRYPTO_METHOD_TLS_CLIENT
In particular:
STREAM_CRYPTO_METHOD_SSLv23_CLIENT
SSLv2
/SSLv3
for 5.5.0 ≤ PHP ≤ 5.6.6 (reference)TLSv1.0
/TLSv1.1
/TLSv1.2
for 5.6.7 ≤ PHP ≤ 7.1.0 (reference)STREAM_CRYPTO_METHOD_TLS_CLIENT
TLSv1.0
/TLSv1.1
/TLSv1.2
for 5.6.0 ≤ PHP ≤ 5.6.6TLSv1.0
for 5.6.7 ≤ PHP ≤ 7.1.0There are some problems with the current implementation:
STREAM_CRYPTO_METHOD_ANY_CLIENT
option introduced in PHP 5.6.0, which evaluates toSSLv2
/SSLv3
/TLSv1.0
/TLSv1.1
/TLSv1.2
)So, what about defining the following transports?
ssl
to enablesslv2
andsslv3
sslv2
to enable onlysslv2
sslv3
to enable onlysslv3
tls
to enabletlsv1.0
andtlsv1.1
andtlsv1.2
tlsv1.0
to enable onlytlsv1.0
tlsv1.1
to enable onlytlsv1.1
tlsv1.2
to enable onlytlsv1.2
*
to enable any kind of connectionsFurthermore, because of security issues, more and more websites disable SSL (both SSLv2 and SSLv3), keeping only TLS connections (see for instance what's doing Google).
So, what about switching from
ssl
totls
as the default transport?The text was updated successfully, but these errors were encountered: