doc: correct tlsSocket.getCipher() description

getCipher() actually includes the protocol version that the cipher was
first supported and *not* the negotiated protocol of the current
connection.

PR-URL: https://github.com/nodejs/node/pull/4995
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
pull/4995/merge
Brian White 2016-01-31 01:28:41 -05:00
parent 2c357a7e3b
commit c41c09375b
1 changed files with 4 additions and 3 deletions

View File

@ -435,14 +435,15 @@ Static boolean value, always `true`. May be used to distinguish TLS sockets
from regular ones.
### tlsSocket.getCipher()
Returns an object representing the cipher name and the SSL/TLS
protocol version of the current connection.
Returns an object representing the cipher name and the SSL/TLS protocol version
that first defined the cipher.
Example:
{ name: 'AES256-SHA', version: 'TLSv1/SSLv3' }
See SSL_CIPHER_get_name() and SSL_CIPHER_get_version() in
https://www.openssl.org/docs/ssl/ssl.html#DEALING_WITH_CIPHERS for more
https://www.openssl.org/docs/manmaster/ssl/SSL_CIPHER_get_name.html for more
information.
### tlsSocket.getEphemeralKeyInfo()