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

Unified Diff: net/ssl/openssl_ssl_util.cc

Issue 598043002: Map SSL errors to SSL_PROTOCOL_ERROR, others to FAILED. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/ssl/openssl_ssl_util.cc
diff --git a/net/ssl/openssl_ssl_util.cc b/net/ssl/openssl_ssl_util.cc
index 53d1b7a78917e0a70299c861ab082daf846f72d8..ffa265e5c515f876056ebc5175bb5d70b557326c 100644
--- a/net/ssl/openssl_ssl_util.cc
+++ b/net/ssl/openssl_ssl_util.cc
@@ -143,7 +143,7 @@ int MapOpenSSLErrorSSL(uint32_t error_code) {
return ERR_SSL_INAPPROPRIATE_FALLBACK;
default:
LOG(WARNING) << "Unmapped error reason: " << ERR_GET_REASON(error_code);
- return ERR_FAILED;
+ return ERR_SSL_PROTOCOL_ERROR;
}
}
@@ -197,7 +197,7 @@ int MapOpenSSLErrorWithDetails(int err,
LOG(ERROR) << "OpenSSL SYSCALL error, earliest error code in "
"error queue: " << ERR_peek_error() << ", errno: "
<< errno;
- return ERR_SSL_PROTOCOL_ERROR;
+ return ERR_FAILED;
case SSL_ERROR_SSL:
// Walk down the error stack to find an SSL or net error.
uint32_t error_code;
@@ -219,7 +219,7 @@ int MapOpenSSLErrorWithDetails(int err,
return -ERR_GET_REASON(error_code);
}
} while (error_code != 0);
- return ERR_SSL_PROTOCOL_ERROR;
+ return ERR_FAILED;
default:
// TODO(joth): Implement full mapping.
LOG(WARNING) << "Unknown OpenSSL error " << err;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698