| Index: net/base/ssl_config_service.cc
|
| diff --git a/net/base/ssl_config_service.cc b/net/base/ssl_config_service.cc
|
| index 5fe01cf360f5c78a693c1b3d00ea209e7ec7d66d..f3a09f0bbfaa84b5b1ec277daa9b7c25e30d04a8 100644
|
| --- a/net/base/ssl_config_service.cc
|
| +++ b/net/base/ssl_config_service.cc
|
| @@ -26,8 +26,16 @@ SSLConfig::~SSLConfig() {
|
|
|
| bool SSLConfig::IsAllowedBadCert(X509Certificate* cert,
|
| int* cert_status) const {
|
| + std::string der_cert;
|
| + if (!cert->GetDEREncoded(&der_cert))
|
| + return false;
|
| + return IsAllowedBadCert(der_cert, cert_status);
|
| +}
|
| +
|
| +bool SSLConfig::IsAllowedBadCert(const base::StringPiece& der_cert,
|
| + int* cert_status) const {
|
| for (size_t i = 0; i < allowed_bad_certs.size(); ++i) {
|
| - if (cert->Equals(allowed_bad_certs[i].cert)) {
|
| + if (der_cert == allowed_bad_certs[i].der_cert) {
|
| if (cert_status)
|
| *cert_status = allowed_bad_certs[i].cert_status;
|
| return true;
|
|
|