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

Side by Side Diff: extensions/browser/crx_file_info.h

Issue 829583002: Validate hash_sha256 checksum on .crx update. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix unittest build for windows. Created 5 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 unified diff | Download patch
« no previous file with comments | « extensions/browser/BUILD.gn ('k') | extensions/browser/crx_file_info.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright (c) 2015 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 EXTENSIONS_BROWSER_CRX_FILE_INFO_H_
6 #define EXTENSIONS_BROWSER_CRX_FILE_INFO_H_
7
8 #include <string>
9
10 #include "base/files/file_path.h"
11
12 namespace extensions {
13
14 // CRXFileInfo holds general information about a cached CRX file
15 struct CRXFileInfo {
16 CRXFileInfo();
17 CRXFileInfo(const std::string& extension_id,
18 const base::FilePath& path,
19 const std::string& hash);
20 CRXFileInfo(const std::string& extension_id, const base::FilePath& path);
21 explicit CRXFileInfo(const base::FilePath& path);
22
23 bool operator==(const CRXFileInfo& that) const;
24
25 // The only mandatory field is the file path, whereas extension_id and hash
26 // are only being checked if those are non-empty.
27 std::string extension_id;
28 base::FilePath path;
29 std::string expected_hash;
30 };
31
32 } // namespace extensions
33
34 #endif // EXTENSIONS_BROWSER_CRX_FILE_H_
OLDNEW
« no previous file with comments | « extensions/browser/BUILD.gn ('k') | extensions/browser/crx_file_info.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698