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

Unified Diff: components/autofill/core/browser/webdata/system_encryptor.cc

Issue 2698103002: Allow embedder to use custom cryptography in Autofill table. (Closed)
Patch Set: Allow embedder to use custom cryptography in Autofill table. Created 3 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
Index: components/autofill/core/browser/webdata/system_encryptor.cc
diff --git a/components/autofill/core/browser/webdata/system_encryptor.cc b/components/autofill/core/browser/webdata/system_encryptor.cc
new file mode 100644
index 0000000000000000000000000000000000000000..1763a03d3e83736983eca59a5e20ab8ae2360845
--- /dev/null
+++ b/components/autofill/core/browser/webdata/system_encryptor.cc
@@ -0,0 +1,21 @@
+// Copyright (c) 2017 The Chromium Authors. All rights reserved.
please use gerrit instead 2017/02/22 19:05:42 no "(c)"
devarajn 2017/02/22 19:24:26 Done.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "components/autofill/core/browser/webdata/system_encryptor.h"
+
+#include "components/os_crypt/os_crypt.h"
+
+namespace autofill {
+
+bool SystemEncryptor::EncryptString16(const base::string16& plaintext,
+ std::string* ciphertext) const {
+ return ::OSCrypt::EncryptString16(plaintext, ciphertext);
+}
+
+bool SystemEncryptor::DecryptString16(const std::string& ciphertext,
+ base::string16* plaintext) const {
+ return ::OSCrypt::DecryptString16(ciphertext, plaintext);
+}
+
+} // namespace autofill

Powered by Google App Engine
This is Rietveld 408576698