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

Side by Side Diff: chrome/browser/enumerate_modules_model_win.h

Issue 12163003: Add FilePath to base namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_ENUMERATE_MODULES_MODEL_WIN_H_ 5 #ifndef CHROME_BROWSER_ENUMERATE_MODULES_MODEL_WIN_H_
6 #define CHROME_BROWSER_ENUMERATE_MODULES_MODEL_WIN_H_ 6 #define CHROME_BROWSER_ENUMERATE_MODULES_MODEL_WIN_H_
7 7
8 #include <utility> 8 #include <utility>
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/gtest_prod_util.h" 11 #include "base/gtest_prod_util.h"
12 #include "base/memory/ref_counted.h" 12 #include "base/memory/ref_counted.h"
13 #include "base/memory/singleton.h" 13 #include "base/memory/singleton.h"
14 #include "base/string16.h" 14 #include "base/string16.h"
15 #include "base/timer.h" 15 #include "base/timer.h"
16 #include "content/public/browser/browser_thread.h" 16 #include "content/public/browser/browser_thread.h"
17 #include "googleurl/src/gurl.h" 17 #include "googleurl/src/gurl.h"
18 18
19 class EnumerateModulesModel; 19 class EnumerateModulesModel;
20 class FilePath;
21 20
22 namespace base { 21 namespace base {
22 class FilePath;
23 class ListValue; 23 class ListValue;
24 } 24 }
25 25
26 // A helper class that implements the enumerate module functionality on the File 26 // A helper class that implements the enumerate module functionality on the File
27 // thread. 27 // thread.
28 class ModuleEnumerator : public base::RefCountedThreadSafe<ModuleEnumerator> { 28 class ModuleEnumerator : public base::RefCountedThreadSafe<ModuleEnumerator> {
29 public: 29 public:
30 // What type of module we are dealing with. Loaded modules are modules we 30 // What type of module we are dealing with. Loaded modules are modules we
31 // detect as loaded in the process at the time of scanning. The others are 31 // detect as loaded in the process at the time of scanning. The others are
32 // modules of interest and may or may not be loaded in the process at the 32 // modules of interest and may or may not be loaded in the process at the
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after
184 // Takes each module in the |enumerated_modules_| vector and matches it 184 // Takes each module in the |enumerated_modules_| vector and matches it
185 // against a fixed blacklist of bad and suspected bad modules. 185 // against a fixed blacklist of bad and suspected bad modules.
186 void MatchAgainstBlacklist(); 186 void MatchAgainstBlacklist();
187 187
188 // This function executes on the UI thread when the scanning and matching 188 // This function executes on the UI thread when the scanning and matching
189 // process is done. It notifies the observer. 189 // process is done. It notifies the observer.
190 void ReportBack(); 190 void ReportBack();
191 191
192 // Given a filename, returns the Subject (who signed it) retrieved from 192 // Given a filename, returns the Subject (who signed it) retrieved from
193 // the digital signature (Authenticode). 193 // the digital signature (Authenticode).
194 string16 GetSubjectNameFromDigitalSignature(const FilePath& filename); 194 string16 GetSubjectNameFromDigitalSignature(const base::FilePath& filename);
195 195
196 // The typedef for the vector that maps a regular file path to %env_var%. 196 // The typedef for the vector that maps a regular file path to %env_var%.
197 typedef std::vector< std::pair<string16, string16> > PathMapping; 197 typedef std::vector< std::pair<string16, string16> > PathMapping;
198 198
199 // The vector of paths to %env_var%, used to account for differences in 199 // The vector of paths to %env_var%, used to account for differences in
200 // where people keep there files, c:\windows vs. d:\windows, etc. 200 // where people keep there files, c:\windows vs. d:\windows, etc.
201 PathMapping path_mapping_; 201 PathMapping path_mapping_;
202 202
203 // The vector containing all the enumerated modules (loaded and modules of 203 // The vector containing all the enumerated modules (loaded and modules of
204 // interest). 204 // interest).
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
309 int confirmed_bad_modules_detected_; 309 int confirmed_bad_modules_detected_;
310 310
311 // The number of suspected bad modules (not including confirmed bad ones) 311 // The number of suspected bad modules (not including confirmed bad ones)
312 // found during last scan. 312 // found during last scan.
313 int suspected_bad_modules_detected_; 313 int suspected_bad_modules_detected_;
314 314
315 DISALLOW_COPY_AND_ASSIGN(EnumerateModulesModel); 315 DISALLOW_COPY_AND_ASSIGN(EnumerateModulesModel);
316 }; 316 };
317 317
318 #endif // CHROME_BROWSER_ENUMERATE_MODULES_MODEL_WIN_H_ 318 #endif // CHROME_BROWSER_ENUMERATE_MODULES_MODEL_WIN_H_
OLDNEW
« no previous file with comments | « chrome/browser/download/download_path_reservation_tracker.h ('k') | chrome/browser/extensions/activity_database.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698