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

Unified Diff: remoting/protocol/jingle_session.cc

Issue 8662001: Remove AccessVerifier interface. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: - Created 9 years, 1 month 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/connection_to_host.cc ('k') | remoting/protocol/jingle_session_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/protocol/jingle_session.cc
diff --git a/remoting/protocol/jingle_session.cc b/remoting/protocol/jingle_session.cc
index 21f8426baa91523e519578a9548b4be39db020d7..8b258f3626bb1ec2e1c7a9808663e9cf8ac67895 100644
--- a/remoting/protocol/jingle_session.cc
+++ b/remoting/protocol/jingle_session.cc
@@ -14,6 +14,7 @@
#include "net/base/net_errors.h"
#include "net/socket/stream_socket.h"
#include "remoting/base/constants.h"
+#include "remoting/protocol/auth_util.h"
#include "remoting/protocol/jingle_datagram_connector.h"
#include "remoting/protocol/jingle_session_manager.h"
#include "remoting/protocol/jingle_stream_connector.h"
@@ -101,6 +102,7 @@ void JingleSession::CloseInternal(int result, Error error) {
reason = cricket::STR_TERMINATE_SUCCESS;
break;
case SESSION_REJECTED:
+ case AUTHENTICATION_FAILED:
reason = cricket::STR_TERMINATE_DECLINE;
break;
case INCOMPATIBLE_PROTOCOL:
@@ -397,6 +399,9 @@ void JingleSession::AcceptConnection() {
delete this;
return;
}
+
+ if (!VerifySupportAuthToken(jid_, shared_secret_, initiator_token()))
+ CloseInternal(net::ERR_CONNECTION_FAILED, AUTHENTICATION_FAILED);
}
void JingleSession::AddChannelConnector(
« no previous file with comments | « remoting/protocol/connection_to_host.cc ('k') | remoting/protocol/jingle_session_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698