Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 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 | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef SANDBOX_SRC_WIN_PROCESS_MITIGATIONS_H_ | |
| 6 #define SANDBOX_SRC_WIN_PROCESS_MITIGATIONS_H_ | |
| 7 | |
| 8 #include <windows.h> | |
| 9 | |
| 10 #include "base/basictypes.h" | |
| 11 | |
| 12 namespace sandbox { | |
| 13 | |
| 14 // Returns the flags that must be enforced after startup. | |
| 15 uint64 GetPostStartupProcessMitigations(uint64 flags); | |
|
rvargas (doing something else)
2012/09/08 02:23:32
It is not clear, from reading this file, what are
rvargas (doing something else)
2012/09/08 02:23:32
btw, make sure the order on the header matches the
| |
| 16 | |
| 17 // Converts sandbox flags to the PROC_THREAD_ATTRIBUTE_SECURITY_CAPABILITIES | |
| 18 // flags used by UpdateProcThreadAttribute(). | |
| 19 DWORD64 GetProcessMitigationPolicyFlags(uint64 flags); | |
|
rvargas (doing something else)
2012/09/08 02:23:32
This looks really weird... convert from uint64 to
jschuh
2012/09/10 23:58:48
I need windows.h for the HANDLE regardless. Howeve
| |
| 20 | |
| 21 // Sets the mitigation policy for the current process, ignoring any settings | |
| 22 // that are invalid for the current version of Windows. | |
| 23 bool SetProcessMitigationsForCurrentProcess(uint64 flags); | |
| 24 | |
| 25 // Adds mitigations that need to be performed on the suspended target process | |
| 26 // before execution begins. | |
| 27 bool SetProcessMitigationsForSuspendedProcess(HANDLE process, uint64 flags); | |
| 28 | |
| 29 // Returns true if all the supplied flags can be set after a process starts. | |
| 30 bool CanSetProcessMitigationsPostStartup(uint64 flags); | |
| 31 | |
| 32 // Returns true if all the supplied flags can be set before a process starts. | |
| 33 bool CanSetProcessMitigationsPreStartup(uint64 flags); | |
| 34 | |
| 35 } // namespace sandbox | |
| 36 | |
| 37 #endif // SANDBOX_SRC_WIN_PROCESS_MITIGATIONS_H_ | |
| 38 | |
| OLD | NEW |