Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/boringssl.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Benjamin <davidben@chromium.org>2015-12-17 10:01:25 +0300
committerAdam Langley <agl@google.com>2015-12-22 20:00:56 +0300
commitae0eaaa397a34eef1d46035bb60c056c3b798e7c (patch)
tree23a8df845837ef45373f14ae32d00d6518f5e7fe /include/openssl/bn.h
parent3ac4b3a391f197edc93a66309a48b7781554d17d (diff)
Convert ssl3_send_client_key_exchange to CBB.
This relieves some complexity budget for adding Curve25519 to this code. This also adds a BN_bn2cbb_padded helper function since this seems to be a fairly common need. Change-Id: Ied0066fdaec9d02659abd6eb1a13f33502c9e198 Reviewed-on: https://boringssl-review.googlesource.com/6767 Reviewed-by: Adam Langley <agl@google.com>
Diffstat (limited to 'include/openssl/bn.h')
-rw-r--r--include/openssl/bn.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/openssl/bn.h b/include/openssl/bn.h
index bc30d0ab..6e971e48 100644
--- a/include/openssl/bn.h
+++ b/include/openssl/bn.h
@@ -253,6 +253,9 @@ OPENSSL_EXPORT size_t BN_bn2bin(const BIGNUM *in, uint8_t *out);
* returns 0. Otherwise, it returns 1. */
OPENSSL_EXPORT int BN_bn2bin_padded(uint8_t *out, size_t len, const BIGNUM *in);
+/* BN_bn2cbb_padded behaves like |BN_bn2bin_padded| but writes to a |CBB|. */
+OPENSSL_EXPORT int BN_bn2cbb_padded(CBB *out, size_t len, const BIGNUM *in);
+
/* BN_bn2hex returns an allocated string that contains a NUL-terminated, hex
* representation of |bn|. If |bn| is negative, the first char in the resulting
* string will be '-'. Returns NULL on allocation failure. */