From 80ec3fffc1220f0f9144b1b5762195e1b623abaa Mon Sep 17 00:00:00 2001 From: "akalin@chromium.org" Date: Thu, 1 Apr 2010 23:25:40 +0000 Subject: Fix for a problem introduced by 41865 which causes sync notifications to break for non-gmail.com accounts. BUG=40054 TEST=manual testing Review URL: http://codereview.chromium.org/1558013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@43409 0039d316-1c4b-4281-b951-d872f2087c98 --- .../sync/notifier/communicator/single_login_attempt.cc | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'chrome') diff --git a/chrome/browser/sync/notifier/communicator/single_login_attempt.cc b/chrome/browser/sync/notifier/communicator/single_login_attempt.cc index de759a6..ff53d68 100644 --- a/chrome/browser/sync/notifier/communicator/single_login_attempt.cc +++ b/chrome/browser/sync/notifier/communicator/single_login_attempt.cc @@ -82,6 +82,22 @@ class GaiaOnlySaslHandler : public buzz::SaslHandler { : NULL; } + virtual bool GetTlsServerInfo(const talk_base::SocketAddress& server, + std::string* tls_server_hostname, + std::string* tls_server_domain) { + std::string server_ip = server.IPAsString(); + if ((server_ip == buzz::STR_TALK_GOOGLE_COM) || + (server_ip == buzz::STR_TALKX_L_GOOGLE_COM)) { + // For Gaia auth, the talk.google.com server expects you to use + // "gmail.com" in the stream, and expects the domain certificate + // to be "gmail.com" as well. + *tls_server_hostname = buzz::STR_GMAIL_COM; + *tls_server_domain = buzz::STR_GMAIL_COM; + return true; + } + return false; + } + private: std::string username_, token_, token_service_; }; -- cgit v1.1