OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "sandbox/win/src/process_mitigations.h" | 5 #include "sandbox/win/src/process_mitigations.h" |
6 | 6 |
| 7 #include <stddef.h> |
| 8 |
7 #include <algorithm> | 9 #include <algorithm> |
8 | 10 |
9 #include "base/win/windows_version.h" | 11 #include "base/win/windows_version.h" |
10 #include "sandbox/win/src/nt_internals.h" | 12 #include "sandbox/win/src/nt_internals.h" |
11 #include "sandbox/win/src/restricted_token_utils.h" | 13 #include "sandbox/win/src/restricted_token_utils.h" |
12 #include "sandbox/win/src/sandbox_rand.h" | 14 #include "sandbox/win/src/sandbox_rand.h" |
13 #include "sandbox/win/src/win_utils.h" | 15 #include "sandbox/win/src/win_utils.h" |
14 | 16 |
15 namespace { | 17 namespace { |
16 | 18 |
(...skipping 305 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
322 } | 324 } |
323 | 325 |
324 bool CanSetProcessMitigationsPreStartup(MitigationFlags flags) { | 326 bool CanSetProcessMitigationsPreStartup(MitigationFlags flags) { |
325 // These mitigations cannot be enabled prior to startup. | 327 // These mitigations cannot be enabled prior to startup. |
326 return !(flags & (MITIGATION_STRICT_HANDLE_CHECKS | | 328 return !(flags & (MITIGATION_STRICT_HANDLE_CHECKS | |
327 MITIGATION_DLL_SEARCH_ORDER)); | 329 MITIGATION_DLL_SEARCH_ORDER)); |
328 } | 330 } |
329 | 331 |
330 } // namespace sandbox | 332 } // namespace sandbox |
331 | 333 |
OLD | NEW |