diff options
author | David Benjamin <davidben@chromium.org> | 2014-12-11 09:46:01 +0300 |
---|---|---|
committer | Adam Langley <agl@google.com> | 2014-12-14 01:38:27 +0300 |
commit | e99e912bea854910c56301985afc3e72dcfe0404 (patch) | |
tree | f937c6fc72697ce4995515d76160b9c744ce11ab /ssl/s3_lib.c | |
parent | ceb6f2880feb600ff76604db6deae15dc2e93899 (diff) |
Pull SSL3_ENC_METHOD out of SSL_METHOD.
SSL3_ENC_METHOD will remain version-specific while SSL_METHOD will become
protocol-specific. This finally removes all the version-specific portions of
SSL_METHOD but the version tag itself.
(SSL3_ENC_METHOD's version-specific bits themselves can probably be handled by
tracking a canonicalized protocol version. It would simplify version
comparisons anyway. The one catch is SSLv3 has a very different table. But
that's a cleanup for future. Then again, perhaps a version-specific method
table swap somewhere will be useful later for TLS 1.3.)
Much of this commit was generated with sed invocation:
s/method->ssl3_enc/enc_method/g
Change-Id: I2b192507876aadd4f9310240687e562e56e6c0b1
Reviewed-on: https://boringssl-review.googlesource.com/2581
Reviewed-by: Adam Langley <agl@google.com>
Diffstat (limited to 'ssl/s3_lib.c')
-rw-r--r-- | ssl/s3_lib.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ssl/s3_lib.c b/ssl/s3_lib.c index d41294a4..8176b2a5 100644 --- a/ssl/s3_lib.c +++ b/ssl/s3_lib.c @@ -2056,7 +2056,7 @@ long ssl_get_algorithm2(SSL *s) { static const unsigned long kMask = SSL_HANDSHAKE_MAC_DEFAULT|TLS1_PRF; long alg2 = s->s3->tmp.new_cipher->algorithm2; - if (s->method->ssl3_enc->enc_flags & SSL_ENC_FLAG_SHA256_PRF + if (s->enc_method->enc_flags & SSL_ENC_FLAG_SHA256_PRF && (alg2 & kMask) == kMask) return SSL_HANDSHAKE_MAC_SHA256 | TLS1_PRF_SHA256; return alg2; |