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 #ifndef SANDBOX_SRC_PROCESS_MITIGATIONS_WIN32K_POLICY_H_ | 5 #ifndef SANDBOX_SRC_PROCESS_MITIGATIONS_WIN32K_POLICY_H_ |
6 #define SANDBOX_SRC_PROCESS_MITIGATIONS_WIN32K_POLICY_H_ | 6 #define SANDBOX_SRC_PROCESS_MITIGATIONS_WIN32K_POLICY_H_ |
7 | 7 |
8 #include "base/basictypes.h" | |
9 #include "sandbox/win/src/crosscall_server.h" | 8 #include "sandbox/win/src/crosscall_server.h" |
10 #include "sandbox/win/src/policy_low_level.h" | 9 #include "sandbox/win/src/policy_low_level.h" |
11 #include "sandbox/win/src/sandbox_policy.h" | 10 #include "sandbox/win/src/sandbox_policy.h" |
12 | 11 |
13 namespace sandbox { | 12 namespace sandbox { |
14 | 13 |
15 enum EvalResult; | 14 enum EvalResult; |
16 | 15 |
17 // This class centralizes most of the knowledge related to the process | 16 // This class centralizes most of the knowledge related to the process |
18 // mitigations Win32K lockdown policy. | 17 // mitigations Win32K lockdown policy. |
19 class ProcessMitigationsWin32KLockdownPolicy { | 18 class ProcessMitigationsWin32KLockdownPolicy { |
20 public: | 19 public: |
21 // Creates the required low-level policy rules to evaluate a high-level | 20 // Creates the required low-level policy rules to evaluate a high-level |
22 // policy rule for the Win32K process mitigation policy. | 21 // policy rule for the Win32K process mitigation policy. |
23 // name is the object name, semantics is the desired semantics for the | 22 // name is the object name, semantics is the desired semantics for the |
24 // open or create and policy is the policy generator to which the rules are | 23 // open or create and policy is the policy generator to which the rules are |
25 // going to be added. | 24 // going to be added. |
26 static bool GenerateRules(const wchar_t* name, | 25 static bool GenerateRules(const wchar_t* name, |
27 TargetPolicy::Semantics semantics, | 26 TargetPolicy::Semantics semantics, |
28 LowLevelPolicy* policy); | 27 LowLevelPolicy* policy); |
29 }; | 28 }; |
30 | 29 |
31 } // namespace sandbox | 30 } // namespace sandbox |
32 | 31 |
33 #endif // SANDBOX_SRC_PROCESS_MITIGATIONS_WIN32K_POLICY_H_ | 32 #endif // SANDBOX_SRC_PROCESS_MITIGATIONS_WIN32K_POLICY_H_ |
34 | 33 |
35 | 34 |
OLD | NEW |