Export SSL_bytes_to_cipher_list()
authorBenjamin Kaduk <bkaduk@akamai.com>
Mon, 30 Jan 2017 17:24:17 +0000 (11:24 -0600)
committerRichard Levitte <levitte@openssl.org>
Thu, 23 Feb 2017 18:40:25 +0000 (19:40 +0100)
commitccb8e6e0b1c536430290a87ba5c87dc072cc5a12
treeb80c31b90ba3f28ce3909348587fb91dc6bed166
parent60d685d196e8d594d754751e4852f01d80d8c0cc
Export SSL_bytes_to_cipher_list()

Move ssl_bytes_to_cipher_list() to ssl_lib.c and create a public
wrapper around it.  This lets application early callbacks easily get
SSL_CIPHER objects from the raw ciphers bytes without having to
reimplement the parsing code.  In particular, they do not need to
know the details of the sslv2 format ClientHello's ciphersuite
specifications.

Document the new public function, including the arguably buggy behavior
of modifying the supplied SSL object.  On the face of it, such a function
should be able to be pure, just a direct translation of wire octets to
internal data structures.

Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Richard Levitte <levitte@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/2279)
doc/man3/SSL_get_ciphers.pod
include/openssl/ssl.h
ssl/ssl_err.c
ssl/ssl_lib.c
ssl/ssl_locl.h
ssl/statem/statem_srvr.c
util/libssl.num