[XDK][KMTESTS:SE] Move the auto inherit ACE flags in the right place

These bit flags are documented in CreatePrivateObjectSecurityEx API routine call in MSDN and their reasonable location should be XDK (NTIFS section more or less) and not Kernel tests suite (KMTESTs). Also assign these flags the right values.

https://docs.microsoft.com/en-us/windows/win32/api/securitybaseapi/nf-securitybaseapi-createprivateobjectsecurityex
This commit is contained in:
George Bișoc 2021-09-08 18:17:41 +02:00
parent 3f4c98a425
commit 58c42afec2
No known key found for this signature in database
GPG key ID: 688C4FBE25D7DEF6
2 changed files with 15 additions and 15 deletions

View file

@ -8,21 +8,6 @@
#ifndef _KMTEST_SE_H_
#define _KMTEST_SE_H_
/* FIXME: belongs in ntifs.h or something */
#define SEF_DACL_AUTO_INHERIT 1
#define SEF_SACL_AUTO_INHERIT 2
#define SEF_DEFAULT_DESCRIPTOR_FOR_OBJECT 4
#define SEF_AVOID_PRIVILEGE_CHECK 8
#define SEF_AVOID_OWNER_CHECK 16
#define SEF_DEFAULT_OWNER_FROM_PARENT 32
#define SEF_DEFAULT_GROUP_FROM_PARENT 64
#define SEF_MACL_NO_WRITE_UP 256
#define SEF_MACL_NO_READ_UP 512
#define SEF_MACL_NO_EXECUTE_UP 1024
#define SEF_AI_USE_EXTRA_PARAMS 2048
#define SEF_AVOID_OWNER_RESTRICTION 4096
#define SEF_MACL_VALID_FLAGS (SEF_MACL_NO_WRITE_UP | SEF_MACL_NO_READ_UP | SEF_MACL_NO_EXECUTE_UP)
NTSTATUS
RtlxAddAuditAccessAceEx(
_Inout_ PACL Acl,

View file

@ -131,6 +131,21 @@ typedef struct _SE_IMPERSONATION_STATE {
#define UNPROTECTED_DACL_SECURITY_INFORMATION (0x20000000L)
#define UNPROTECTED_SACL_SECURITY_INFORMATION (0x10000000L)
/* Auto inherit ACE flags */
#define SEF_DACL_AUTO_INHERIT 0x01
#define SEF_SACL_AUTO_INHERIT 0x02
#define SEF_DEFAULT_DESCRIPTOR_FOR_OBJECT 0x04
#define SEF_AVOID_PRIVILEGE_CHECK 0x08
#define SEF_AVOID_OWNER_CHECK 0x10
#define SEF_DEFAULT_OWNER_FROM_PARENT 0x20
#define SEF_DEFAULT_GROUP_FROM_PARENT 0x40
#define SEF_MACL_NO_WRITE_UP 0x100
#define SEF_MACL_NO_READ_UP 0x200
#define SEF_MACL_NO_EXECUTE_UP 0x400
#define SEF_AI_USE_EXTRA_PARAMS 0x800
#define SEF_AVOID_OWNER_RESTRICTION 0x1000
#define SEF_MACL_VALID_FLAGS (SEF_MACL_NO_WRITE_UP | SEF_MACL_NO_READ_UP | SEF_MACL_NO_EXECUTE_UP)
$endif (_WDMDDK_ || _WINNT_)
$if (_WDMDDK_)