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

Unified Diff: components/password_manager/core/browser/login_database.cc

Issue 1752383004: CREDENTIAL: Serialize 'PasswordCredential' objects with "" as the federation. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2661
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 | « chrome/browser/password_manager/native_backend_libsecret_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/password_manager/core/browser/login_database.cc
diff --git a/components/password_manager/core/browser/login_database.cc b/components/password_manager/core/browser/login_database.cc
index 813821256dcae6235f3b1e927f02ff223bb06cf8..fa1eb1be747795cdf5e8be9ba941e320817f6075 100644
--- a/components/password_manager/core/browser/login_database.cc
+++ b/components/password_manager/core/browser/login_database.cc
@@ -941,7 +941,11 @@ PasswordStoreChangeList LoginDatabase::UpdateLogin(const PasswordForm& form) {
s.BindInt(11, form.type);
s.BindString16(12, form.display_name);
s.BindString(13, form.icon_url.spec());
- s.BindString(14, form.federation_origin.Serialize());
+ // We serialize unique origins as "", in order to make other systems that
+ // read from the login database happy. https://crbug.com/591310
+ s.BindString(14, form.federation_origin.unique()
+ ? std::string()
+ : form.federation_origin.Serialize());
s.BindInt(15, form.skip_zero_click);
s.BindInt(16, form.generation_upload_status);
« no previous file with comments | « chrome/browser/password_manager/native_backend_libsecret_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698