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

Unified Diff: remoting/protocol/v2_authenticator.cc

Issue 1739503003: Ignore host certificate in remoting::V2Authenticator on the client side. Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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 | « remoting/protocol/v2_authenticator.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/protocol/v2_authenticator.cc
diff --git a/remoting/protocol/v2_authenticator.cc b/remoting/protocol/v2_authenticator.cc
index a17fb466c116f9adc1ae7517b503652ba681d47d..bbb8919b0d6b4fe72ce0fc0d5c355aad1aa59953 100644
--- a/remoting/protocol/v2_authenticator.cc
+++ b/remoting/protocol/v2_authenticator.cc
@@ -92,23 +92,6 @@ void V2Authenticator::ProcessMessage(const buzz::XmlElement* message,
void V2Authenticator::ProcessMessageInternal(const buzz::XmlElement* message) {
DCHECK_EQ(state(), WAITING_MESSAGE);
- // Parse the certificate.
- std::string base64_cert = message->TextNamed(kCertificateTag);
- if (!base64_cert.empty()) {
- if (!base::Base64Decode(base64_cert, &remote_cert_)) {
- LOG(WARNING) << "Failed to decode certificate received from the peer.";
- remote_cert_.clear();
- }
- }
-
- // Client always expect certificate in the first message.
- if (!is_host_side() && remote_cert_.empty()) {
- LOG(WARNING) << "No valid host certificate.";
- state_ = REJECTED;
- rejection_reason_ = PROTOCOL_ERROR;
- return;
- }
-
const buzz::XmlElement* eke_element = message->FirstNamed(kEkeTag);
if (!eke_element) {
LOG(WARNING) << "No eke-message found.";
@@ -196,8 +179,7 @@ V2Authenticator::CreateChannelAuthenticator() const {
return SslHmacChannelAuthenticator::CreateForHost(
local_cert_, local_key_pair_, auth_key_);
} else {
- return SslHmacChannelAuthenticator::CreateForClient(
- remote_cert_, auth_key_);
+ return SslHmacChannelAuthenticator::CreateForClient(auth_key_);
}
}
« no previous file with comments | « remoting/protocol/v2_authenticator.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698