New issue
Advanced search Search tips

Issue 859622 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner: ----
Closed: Aug 17
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Android , Windows , Chrome , Mac
Pri: 3
Type: Bug



Sign in to add a comment

gaia::CanonicalizeEmail(..) doesn't handle upper case email address correctly.

Project Member Reported by jialiul@chromium.org, Jul 2

Issue description

CanonicalizeEmailImpl(..) function converts the email address to lower case at the last step. As a result, emails with upper case "GMAIL.COM" suffix are not canonicalized correct. 

e.g.:  CanonicalizeEmail("USER.NAME@GMAIL.COM") returns "user.name@gmail.com".  but should return "username@gmail.com".  
 
Project Member

Comment 1 by bugdroid1@chromium.org, Aug 16

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/766926fd2c3742e8fef16675120f72ff4424a949

commit 766926fd2c3742e8fef16675120f72ff4424a949
Author: Jialiu Lin <jialiul@chromium.org>
Date: Thu Aug 16 18:37:19 2018

Refine gaia::CanonicalizeEmail(..)

1. Previously gaia::CanonicalizeEmail(..) didn't handle upper case gmail correctly.
e.g.:  CanonicalizeEmail("USER.NAME@GMAIL.COM") previously return
"user.name@gmail.com". Instead it should return "username@gmail.com".

2. When input is not a valid email, instead of triggering NOTREACHED,
it now returns the input in lower case. In this way, the downstream use of this
method can be more flexible.

Bug: 874050,  859622 
Change-Id: I2aeeb30cb1cd69c65b96de0fdd3a8c00cb2f274e
Reviewed-on: https://chromium-review.googlesource.com/1174909
Reviewed-by: Roger Tawa <rogerta@chromium.org>
Reviewed-by: Jialiu Lin <jialiul@chromium.org>
Commit-Queue: Jialiu Lin <jialiul@chromium.org>
Cr-Commit-Position: refs/heads/master@{#583754}
[modify] https://crrev.com/766926fd2c3742e8fef16675120f72ff4424a949/google_apis/gaia/gaia_auth_util.cc
[modify] https://crrev.com/766926fd2c3742e8fef16675120f72ff4424a949/google_apis/gaia/gaia_auth_util.h
[modify] https://crrev.com/766926fd2c3742e8fef16675120f72ff4424a949/google_apis/gaia/gaia_auth_util_unittest.cc

Status: Fixed (was: Untriaged)

Sign in to add a comment