shim: call SSL_CTX_set_tlsext_ticket_keys() only once.
rather than twice, with the second call overriding the first. Change-Id: Ieb139928edcbe75f1d2e7c2c52c46950d6343a6c Reviewed-on: https://boringssl-review.googlesource.com/29904 Commit-Queue: Adam Langley <agl@google.com> CQ-Verified: CQ bot account: commit-bot@chromium.org <commit-bot@chromium.org> Reviewed-by: Adam Langley <agl@google.com>
This commit is contained in:
parent
6d597a34b6
commit
d154c7ccbc
@ -1235,12 +1235,6 @@ bssl::UniquePtr<SSL_CTX> TestConfig::SetupCtx(SSL_CTX *old_ctx) const {
|
|||||||
SSL_CTX_set_tlsext_servername_callback(ssl_ctx.get(), ServerNameCallback);
|
SSL_CTX_set_tlsext_servername_callback(ssl_ctx.get(), ServerNameCallback);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!ticket_key.empty() &&
|
|
||||||
!SSL_CTX_set_tlsext_ticket_keys(ssl_ctx.get(), ticket_key.data(),
|
|
||||||
ticket_key.size())) {
|
|
||||||
return nullptr;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (enable_early_data) {
|
if (enable_early_data) {
|
||||||
SSL_CTX_set_early_data_enabled(ssl_ctx.get(), 1);
|
SSL_CTX_set_early_data_enabled(ssl_ctx.get(), 1);
|
||||||
}
|
}
|
||||||
@ -1284,8 +1278,13 @@ bssl::UniquePtr<SSL_CTX> TestConfig::SetupCtx(SSL_CTX *old_ctx) const {
|
|||||||
return nullptr;
|
return nullptr;
|
||||||
}
|
}
|
||||||
CopySessions(ssl_ctx.get(), old_ctx);
|
CopySessions(ssl_ctx.get(), old_ctx);
|
||||||
|
} else if (!ticket_key.empty() &&
|
||||||
|
!SSL_CTX_set_tlsext_ticket_keys(ssl_ctx.get(), ticket_key.data(),
|
||||||
|
ticket_key.size())) {
|
||||||
|
return nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if (install_cert_compression_algs &&
|
if (install_cert_compression_algs &&
|
||||||
(!SSL_CTX_add_cert_compression_alg(
|
(!SSL_CTX_add_cert_compression_alg(
|
||||||
ssl_ctx.get(), 0xff02,
|
ssl_ctx.get(), 0xff02,
|
||||||
|
Loading…
Reference in New Issue
Block a user