Opaquify SSL_CIPHER.
Bug: 6
Change-Id: Ieb2a8816b63425dce64e26ac41ded894a6c5e61b
Reviewed-on: https://boringssl-review.googlesource.com/20264
Commit-Queue: David Benjamin <davidben@google.com>
Commit-Queue: Steven Valdez <svaldez@google.com>
Reviewed-by: Steven Valdez <svaldez@google.com>
CQ-Verified: CQ bot account: commit-bot@chromium.org <commit-bot@chromium.org>
diff --git a/include/openssl/ssl.h b/include/openssl/ssl.h
index 36f61a6..e9eb236 100644
--- a/include/openssl/ssl.h
+++ b/include/openssl/ssl.h
@@ -3981,22 +3981,6 @@
DECLARE_STACK_OF(SSL_CUSTOM_EXTENSION)
-struct ssl_cipher_st {
- // name is the OpenSSL name for the cipher.
- const char *name;
- // standard_name is the IETF name for the cipher.
- const char *standard_name;
- // id is the cipher suite value bitwise OR-d with 0x03000000.
- uint32_t id;
-
- // algorithm_* are internal fields. See ssl/internal.h for their values.
- uint32_t algorithm_mkey;
- uint32_t algorithm_auth;
- uint32_t algorithm_enc;
- uint32_t algorithm_mac;
- uint32_t algorithm_prf;
-};
-
#define SSL_MAX_SSL_SESSION_ID_LENGTH 32
#define SSL_MAX_SID_CTX_LENGTH 32
#define SSL_MAX_MASTER_KEY_LENGTH 48
diff --git a/ssl/internal.h b/ssl/internal.h
index 2fb3614..9e67457 100644
--- a/ssl/internal.h
+++ b/ssl/internal.h
@@ -302,6 +302,26 @@
// Cipher suites.
+} // namespace bssl
+
+struct ssl_cipher_st {
+ // name is the OpenSSL name for the cipher.
+ const char *name;
+ // standard_name is the IETF name for the cipher.
+ const char *standard_name;
+ // id is the cipher suite value bitwise OR-d with 0x03000000.
+ uint32_t id;
+
+ // algorithm_* determine the cipher suite. See constants below for the values.
+ uint32_t algorithm_mkey;
+ uint32_t algorithm_auth;
+ uint32_t algorithm_enc;
+ uint32_t algorithm_mac;
+ uint32_t algorithm_prf;
+};
+
+namespace bssl {
+
// Bits for |algorithm_mkey| (key exchange algorithm).
#define SSL_kRSA 0x00000001u
#define SSL_kECDHE 0x00000002u