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

Unified Diff: net/cert/cert_verify_proc_builtin.cc

Issue 2951343002: Remove residual support for SHA-1 public key pins. (Closed)
Patch Set: Remove the rest of HASH_VALUE_SHA1; respond to comments. Created 3 years, 6 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
Index: net/cert/cert_verify_proc_builtin.cc
diff --git a/net/cert/cert_verify_proc_builtin.cc b/net/cert/cert_verify_proc_builtin.cc
index 2ed89b649df10cb610d1a0d5d2de4bacffd5fee0..3261d2b9bf62e76c1258929aea6083dcd0b0d4cb 100644
--- a/net/cert/cert_verify_proc_builtin.cc
+++ b/net/cert/cert_verify_proc_builtin.cc
@@ -89,14 +89,9 @@ void AddIntermediatesToIssuerSource(X509Certificate* x509_cert,
}
}
-// Appends the SHA1 and SHA256 hashes of |spki_bytes| to |*hashes|.
+// Appends the SHA256 hashes of |spki_bytes| to |*hashes|.
void AppendPublicKeyHashes(const der::Input& spki_bytes,
HashValueVector* hashes) {
- HashValue sha1(HASH_VALUE_SHA1);
- base::SHA1HashBytes(spki_bytes.UnsafeData(), spki_bytes.Length(),
- sha1.data());
- hashes->push_back(sha1);
-
HashValue sha256(HASH_VALUE_SHA256);
crypto::SHA256HashString(spki_bytes.AsStringPiece(), sha256.data(),
crypto::kSHA256Length);

Powered by Google App Engine
This is Rietveld 408576698