diff options
author | Paul Yang <yang.yang@baishancloud.com> | 2017-08-23 00:37:10 +0800 |
---|---|---|
committer | Benjamin Kaduk <kaduk@mit.edu> | 2017-08-30 14:01:13 -0500 |
commit | 50966bfa119d129c4b2bc405b6ade1c6a21b84f2 (patch) | |
tree | d36649684cf1ff69c6fb264ef7daf50c46aaf620 /doc | |
parent | 22d1a340b644d5d833157de1c0c2d1f0d7690529 (diff) | |
download | openssl-50966bfa119d129c4b2bc405b6ade1c6a21b84f2.tar.gz |
Introduce SSL_CIPHER_get_protocol_id
The returned ID matches with what IANA specifies (or goes on the
wire anyway, IANA notwithstanding).
Doc is added.
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Ben Kaduk <kaduk@mit.edu>
(Merged from https://github.com/openssl/openssl/pull/4107)
Diffstat (limited to 'doc')
-rw-r--r-- | doc/man3/SSL_CIPHER_get_name.pod | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/doc/man3/SSL_CIPHER_get_name.pod b/doc/man3/SSL_CIPHER_get_name.pod index 2f8dcae9f7..c82be8e4e2 100644 --- a/doc/man3/SSL_CIPHER_get_name.pod +++ b/doc/man3/SSL_CIPHER_get_name.pod @@ -15,7 +15,8 @@ SSL_CIPHER_get_kx_nid, SSL_CIPHER_get_auth_nid, SSL_CIPHER_is_aead, SSL_CIPHER_find, -SSL_CIPHER_get_id +SSL_CIPHER_get_id, +SSL_CIPHER_get_protocol_id - get SSL_CIPHER properties =head1 SYNOPSIS @@ -36,6 +37,7 @@ SSL_CIPHER_get_id int SSL_CIPHER_is_aead(const SSL_CIPHER *c); const SSL_CIPHER *SSL_CIPHER_find(SSL *ssl, const unsigned char *ptr); uint32_t SSL_CIPHER_get_id(const SSL_CIPHER *c); + uint32_t SSL_CIPHER_get_protocol_id(const SSL_CIPHER *c); =head1 DESCRIPTION @@ -98,11 +100,11 @@ two-byte TLS cipher ID (as allocated by IANA) in network byte order. This parame is usually retrieved from a TLS packet by using functions like L<SSL_early_get0_ciphers(3)>. SSL_CIPHER_find() returns NULL if an error occurs or the indicated cipher is not found. -SSL_CIPHER_get_id() returns the ID of the given cipher B<c>. The ID here is an -OpenSSL-specific concept, which stores a prefix of 0x0300 in the higher two bytes, -and the IANA-specified chipher suite ID in the lower two bytes. For instance, -TLS_RSA_WITH_NULL_MD5 has IANA ID "0x00, 0x01", but the SSL_CIPHER_get_id() -function will return an ID with value 0x03000001. +SSL_CIPHER_get_id() returns the OpenSSL-specific ID of the given cipher B<c>. That ID is +not the same as the IANA-specific ID. + +SSL_CIPHER_get_protocol_id() returns the two-byte ID used in the TLS protocol of the given +cipher B<c>. SSL_CIPHER_description() returns a textual description of the cipher used into the buffer B<buf> of length B<len> provided. If B<buf> is provided, it |