| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #include "chrome/browser/safe_browsing/incident_reporting/binary_integrity_analy
zer_win.h" | 5 #include "chrome/browser/safe_browsing/incident_reporting/binary_integrity_analy
zer_win.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| 11 #include "base/files/file_path.h" | 11 #include "base/files/file_path.h" |
| 12 #include "base/files/file_util.h" | 12 #include "base/files/file_util.h" |
| 13 #include "base/logging.h" | 13 #include "base/logging.h" |
| 14 #include "base/macros.h" | 14 #include "base/macros.h" |
| 15 #include "base/memory/ptr_util.h" | 15 #include "base/memory/ptr_util.h" |
| 16 #include "base/path_service.h" | 16 #include "base/path_service.h" |
| 17 #include "chrome/browser/safe_browsing/incident_reporting/binary_integrity_incid
ent.h" | 17 #include "chrome/browser/safe_browsing/incident_reporting/binary_integrity_incid
ent.h" |
| 18 #include "chrome/browser/safe_browsing/incident_reporting/incident_receiver.h" | 18 #include "chrome/browser/safe_browsing/incident_reporting/incident_receiver.h" |
| 19 #include "chrome/common/chrome_version.h" | 19 #include "chrome/common/chrome_version.h" |
| 20 #include "chrome/common/safe_browsing/binary_feature_extractor.h" | 20 #include "chrome/common/safe_browsing/binary_feature_extractor.h" |
| 21 #include "chrome/common/safe_browsing/csd.pb.h" | 21 #include "components/safe_browsing/csd.pb.h" |
| 22 | 22 |
| 23 namespace safe_browsing { | 23 namespace safe_browsing { |
| 24 | 24 |
| 25 std::vector<base::FilePath> GetCriticalBinariesPath() { | 25 std::vector<base::FilePath> GetCriticalBinariesPath() { |
| 26 static const base::FilePath::CharType* const kUnversionedFiles[] = { | 26 static const base::FilePath::CharType* const kUnversionedFiles[] = { |
| 27 FILE_PATH_LITERAL("chrome.exe"), | 27 FILE_PATH_LITERAL("chrome.exe"), |
| 28 }; | 28 }; |
| 29 static const base::FilePath::CharType* const kVersionedFiles[] = { | 29 static const base::FilePath::CharType* const kVersionedFiles[] = { |
| 30 FILE_PATH_LITERAL("chrome.dll"), | 30 FILE_PATH_LITERAL("chrome.dll"), |
| 31 FILE_PATH_LITERAL("chrome_child.dll"), | 31 FILE_PATH_LITERAL("chrome_child.dll"), |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 87 } else { | 87 } else { |
| 88 // The binary is integral, remove previous report so that next incidents | 88 // The binary is integral, remove previous report so that next incidents |
| 89 // for the binary will be reported. | 89 // for the binary will be reported. |
| 90 ClearBinaryIntegrityForFile(incident_receiver.get(), | 90 ClearBinaryIntegrityForFile(incident_receiver.get(), |
| 91 binary_path.BaseName().AsUTF8Unsafe()); | 91 binary_path.BaseName().AsUTF8Unsafe()); |
| 92 } | 92 } |
| 93 } | 93 } |
| 94 } | 94 } |
| 95 | 95 |
| 96 } // namespace safe_browsing | 96 } // namespace safe_browsing |
| OLD | NEW |