Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(156)

Unified Diff: chrome/browser/ssl/chrome_security_state_model_client.cc

Issue 2395323002: Roll src/third_party/boringssl/src 0d81373f9..1991af690 (Closed)
Patch Set: rebase, roll further Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « DEPS ('k') | chrome/browser/ssl/chrome_security_state_model_client_browser_tests.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ssl/chrome_security_state_model_client.cc
diff --git a/chrome/browser/ssl/chrome_security_state_model_client.cc b/chrome/browser/ssl/chrome_security_state_model_client.cc
index 51cd505bc34bbffe981a309fd96a2da7606d819a..8f5d32328e6692928f96b00fe9628fdbbe380688 100644
--- a/chrome/browser/ssl/chrome_security_state_model_client.cc
+++ b/chrome/browser/ssl/chrome_security_state_model_client.cc
@@ -82,12 +82,12 @@ void AddConnectionExplanation(
const char* cipher;
const char* mac;
bool is_aead;
+ bool is_tls13;
uint16_t cipher_suite =
net::SSLConnectionStatusToCipherSuite(security_info.connection_status);
net::SSLCipherSuiteToStrings(&key_exchange, &cipher, &mac, &is_aead,
- cipher_suite);
+ &is_tls13, cipher_suite);
base::string16 protocol_name = base::ASCIIToUTF16(protocol);
- base::string16 key_exchange_name = base::ASCIIToUTF16(key_exchange);
const base::string16 cipher_name =
(mac == NULL) ? base::ASCIIToUTF16(cipher)
: l10n_util::GetStringFUTF16(IDS_CIPHER_WITH_MAC,
@@ -95,15 +95,17 @@ void AddConnectionExplanation(
base::ASCIIToUTF16(mac));
// Include the key exchange group (previously known as curve) if specified.
- //
- // TODO(davidben): When TLS 1.3's new negotiation is implemented, omit the
- // "key exchange" if empty and only display the group, which is the true key
- // exchange. See https://crbug.com/639495.
- if (security_info.key_exchange_group != 0) {
+ base::string16 key_exchange_name;
+ if (is_tls13) {
+ key_exchange_name = base::ASCIIToUTF16(
+ SSL_get_curve_name(security_info.key_exchange_group));
+ } else if (security_info.key_exchange_group != 0) {
key_exchange_name = l10n_util::GetStringFUTF16(
- IDS_SSL_KEY_EXCHANGE_WITH_GROUP, key_exchange_name,
+ IDS_SSL_KEY_EXCHANGE_WITH_GROUP, base::ASCIIToUTF16(key_exchange),
base::ASCIIToUTF16(
SSL_get_curve_name(security_info.key_exchange_group)));
+ } else {
+ key_exchange_name = base::ASCIIToUTF16(key_exchange);
}
if (security_info.obsolete_ssl_status == net::OBSOLETE_SSL_NONE) {
« no previous file with comments | « DEPS ('k') | chrome/browser/ssl/chrome_security_state_model_client_browser_tests.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698