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

Side by Side Diff: google_apis/gaia/gaia_auth_util.cc

Issue 11185002: No need to support dasher domains. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | google_apis/gaia/gaia_auth_util_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "google_apis/gaia/gaia_auth_util.h" 5 #include "google_apis/gaia/gaia_auth_util.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/string_split.h" 10 #include "base/string_split.h"
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 return email.substr(separator_pos + 1); 57 return email.substr(separator_pos + 1);
58 else 58 else
59 NOTREACHED() << "Not a proper email address: " << email; 59 NOTREACHED() << "Not a proper email address: " << email;
60 return std::string(); 60 return std::string();
61 } 61 }
62 62
63 bool IsGaiaSignonRealm(const GURL& url) { 63 bool IsGaiaSignonRealm(const GURL& url) {
64 if (!url.SchemeIsSecure()) 64 if (!url.SchemeIsSecure())
65 return false; 65 return false;
66 66
67 // Also check "https://www.google.com" to support old style dasher logins. 67 return url == GURL(GaiaUrls::GetInstance()->gaia_origin_url());
68 return url == GURL(GaiaUrls::GetInstance()->gaia_origin_url()) ||
69 url == GURL("https://www.google.com/");
70 } 68 }
71 69
72 } // namespace gaia 70 } // namespace gaia
OLDNEW
« no previous file with comments | « no previous file | google_apis/gaia/gaia_auth_util_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698