5

Auditing tools like
https://sslanalyzer.comodoca.com/?url=www.google.com
report that SSL v3 is disabled on www.google.com (as you'd expect; with the security flaws that have been discovered in SSL v3, a company like Google isn't going to forget to turn it off).

But then, how come when I connect to it with openssl and grep the output for "ssl":

openssl s_client -state -connect www.google.com:443 | grep -i "ssl"

the output references SSLv3 multiple times?

SSL_connect:before/connect initialization
SSL_connect:SSLv2/v3 write client hello A
SSL_connect:SSLv3 read server hello A
depth=1 /C=US/O=Google Trust Services/CN=Google Internet Authority G3
verify error:num=20:unable to get local issuer certificate
verify return:0
SSL_connect:SSLv3 read server certificate A
SSL_connect:SSLv3 read server done A
SSL_connect:SSLv3 write client key exchange A
SSL_connect:SSLv3 write change cipher spec A
SSL_connect:SSLv3 write finished A
SSL_connect:SSLv3 flush data
SSL_connect:SSLv3 read finished A
SSL handshake has read 2450 bytes and written 447 bytes
New, TLSv1/SSLv3, Cipher is AES128-SHA
SSL-Session:

I do see the reference to "TLSv1/SSLv3". I've heard that "TLS uses SSL certificates" although I don't understand the details, but does that mean that this connection is using the TLS protocol but using SSLv3 certificates, and that's why I see all the references to SSLv3 even though we're not using the SSLv3 protocol?

(I assume this is more of a conceptual question than a programming question which is why I'm posting it here instead of Stack Overflow.)

1
  • If you look at the indented lines after SSL -Session: which you did not post, the line for Protocol: tells the protocol version that was negotiated. You can also specify the exact version to negotiate with -ssl3 or -tls1 (or -tls1_1 or -tls1_2 in OpenSSL 1.0.1 up) and see them fail and succeed respectively. May 24, 2018 at 1:37

1 Answer 1

8

These messages are coming from SSL_state_string_long, and many of them were updated in version 1.1.0 from "SSLv3 [message]" to "SSLv3/TLS [message]", so my guess would be that OpenSSL uses the same code for SSL 3 and TLS handshakes, and you're just using a version before 1.1.0 where the messages weren't yet updated to account for that.

You can see here and here for 1.0.2 that TLS uses many ssl3 functions, only swapping out those that are incompatible. This has been moved in 1.1.0 so that all of the implementations are in methods.c.

3
  • Oh OK yes mine is ancient, OpenSSL 0.9.8e.
    – Bennett
    May 23, 2018 at 21:42
  • Relatedly note the function names in the code, which appear in the errorstack display, are ssl3_ for some functions also used by TLS, and tls1_ for some functions shared with 1.1 and 1.2 (and 1.3, in OpenSSL 1.1.1 only) May 24, 2018 at 1:39
  • @dave_thompson_085 I noticed that when I was debugging but forgot to include it in my answer, thanks for the reminder! May 24, 2018 at 13:12

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .