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

Side by Side Diff: chrome/browser/importer/nss_decryptor_linux.h

Issue 159165: Split NSSDecryptor out into platform specific files.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 5 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
Property Changes:
Name: svn:eol-style
+ LF
OLDNEW
(Empty)
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_IMPORTER_NSS_DECRYPTOR_LINUX_H_
6 #define CHROME_BROWSER_IMPORTER_NSS_DECRYPTOR_LINUX_H_
7
8 #include <string>
9 #include <vector>
10
11 #include "base/basictypes.h"
12
13 namespace webkit_glue {
14 struct PasswordForm;
15 }
16
17 // A wrapper for Firefox NSS decrypt component.
18 class NSSDecryptor {
19 public:
20 NSSDecryptor();
21 ~NSSDecryptor();
22
23 // Initializes NSS if it hasn't already been initialized.
24 bool Init(const std::wstring& /* dll_path */,
25 const std::wstring& /* db_path */);
26
27 // Decrypts Firefox stored passwords. Before using this method,
28 // make sure Init() returns true.
29 std::wstring Decrypt(const std::string& crypt) const;
30
31 // Parses the Firefox password file content, decrypts the
32 // username/password and reads other related information.
33 // The result will be stored in |forms|.
34 void ParseSignons(const std::string& content,
35 std::vector<webkit_glue::PasswordForm>* forms);
36
37 private:
38 bool is_nss_initialized_;
39
40 DISALLOW_COPY_AND_ASSIGN(NSSDecryptor);
41 };
42
43 #endif // CHROME_BROWSER_IMPORTER_NSS_DECRYPTOR_LINUX_H_
OLDNEW
« no previous file with comments | « chrome/browser/importer/nss_decryptor.cc ('k') | chrome/browser/importer/nss_decryptor_linux.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698