* security.h (DBGSID): Define for debugging purposes.
(MKSID): Rename from SID so as to not hide SID definition from winnt.h. * sec_helper.cc: Change SID to MKSID throughout.
This commit is contained in:
parent
23f710014d
commit
124b187f16
|
@ -1,3 +1,9 @@
|
||||||
|
2006-11-23 Corinna Vinschen <corinna@vinschen.de>
|
||||||
|
|
||||||
|
* security.h (DBGSID): Define for debugging purposes.
|
||||||
|
(MKSID): Rename from SID so as to not hide SID definition from winnt.h.
|
||||||
|
* sec_helper.cc: Change SID to MKSID throughout.
|
||||||
|
|
||||||
2006-11-23 Corinna Vinschen <corinna@vinschen.de>
|
2006-11-23 Corinna Vinschen <corinna@vinschen.de>
|
||||||
|
|
||||||
* net.cc (get_ipv6_funcs): Fix formatting.
|
* net.cc (get_ipv6_funcs): Fix formatting.
|
||||||
|
|
|
@ -38,44 +38,44 @@ SECURITY_ATTRIBUTES NO_COPY sec_none_nih;
|
||||||
SECURITY_ATTRIBUTES NO_COPY sec_all;
|
SECURITY_ATTRIBUTES NO_COPY sec_all;
|
||||||
SECURITY_ATTRIBUTES NO_COPY sec_all_nih;
|
SECURITY_ATTRIBUTES NO_COPY sec_all_nih;
|
||||||
|
|
||||||
SID (well_known_null_sid, "S-1-0-0",
|
MKSID (well_known_null_sid, "S-1-0-0",
|
||||||
SECURITY_NULL_SID_AUTHORITY, 1, SECURITY_NULL_RID);
|
SECURITY_NULL_SID_AUTHORITY, 1, SECURITY_NULL_RID);
|
||||||
SID (well_known_world_sid, "S-1-1-0",
|
MKSID (well_known_world_sid, "S-1-1-0",
|
||||||
SECURITY_WORLD_SID_AUTHORITY, 1, SECURITY_WORLD_RID);
|
SECURITY_WORLD_SID_AUTHORITY, 1, SECURITY_WORLD_RID);
|
||||||
SID (well_known_local_sid, "S-1-2-0",
|
MKSID (well_known_local_sid, "S-1-2-0",
|
||||||
SECURITY_LOCAL_SID_AUTHORITY, 1, SECURITY_LOCAL_RID);
|
SECURITY_LOCAL_SID_AUTHORITY, 1, SECURITY_LOCAL_RID);
|
||||||
SID (well_known_creator_owner_sid, "S-1-3-0",
|
MKSID (well_known_creator_owner_sid, "S-1-3-0",
|
||||||
SECURITY_CREATOR_SID_AUTHORITY, 1, SECURITY_CREATOR_OWNER_RID);
|
SECURITY_CREATOR_SID_AUTHORITY, 1, SECURITY_CREATOR_OWNER_RID);
|
||||||
SID (well_known_creator_group_sid, "S-1-3-1",
|
MKSID (well_known_creator_group_sid, "S-1-3-1",
|
||||||
SECURITY_CREATOR_SID_AUTHORITY, 1, SECURITY_CREATOR_GROUP_RID);
|
SECURITY_CREATOR_SID_AUTHORITY, 1, SECURITY_CREATOR_GROUP_RID);
|
||||||
SID (well_known_dialup_sid, "S-1-5-1",
|
MKSID (well_known_dialup_sid, "S-1-5-1",
|
||||||
SECURITY_NT_AUTHORITY, 1, SECURITY_DIALUP_RID);
|
SECURITY_NT_AUTHORITY, 1, SECURITY_DIALUP_RID);
|
||||||
SID (well_known_network_sid, "S-1-5-2",
|
MKSID (well_known_network_sid, "S-1-5-2",
|
||||||
SECURITY_NT_AUTHORITY, 1, SECURITY_NETWORK_RID);
|
SECURITY_NT_AUTHORITY, 1, SECURITY_NETWORK_RID);
|
||||||
SID (well_known_batch_sid, "S-1-5-3",
|
MKSID (well_known_batch_sid, "S-1-5-3",
|
||||||
SECURITY_NT_AUTHORITY, 1, SECURITY_BATCH_RID);
|
SECURITY_NT_AUTHORITY, 1, SECURITY_BATCH_RID);
|
||||||
SID (well_known_interactive_sid, "S-1-5-4",
|
MKSID (well_known_interactive_sid, "S-1-5-4",
|
||||||
SECURITY_NT_AUTHORITY, 1, SECURITY_INTERACTIVE_RID);
|
SECURITY_NT_AUTHORITY, 1, SECURITY_INTERACTIVE_RID);
|
||||||
SID (well_known_service_sid, "S-1-5-6",
|
MKSID (well_known_service_sid, "S-1-5-6",
|
||||||
SECURITY_NT_AUTHORITY, 1, SECURITY_SERVICE_RID);
|
SECURITY_NT_AUTHORITY, 1, SECURITY_SERVICE_RID);
|
||||||
SID (well_known_authenticated_users_sid, "S-1-5-11",
|
MKSID (well_known_authenticated_users_sid, "S-1-5-11",
|
||||||
SECURITY_NT_AUTHORITY, 1, SECURITY_AUTHENTICATED_USER_RID);
|
SECURITY_NT_AUTHORITY, 1, SECURITY_AUTHENTICATED_USER_RID);
|
||||||
SID (well_known_this_org_sid, "S-1-5-15",
|
MKSID (well_known_this_org_sid, "S-1-5-15",
|
||||||
SECURITY_NT_AUTHORITY, 1, 15);
|
SECURITY_NT_AUTHORITY, 1, 15);
|
||||||
SID (well_known_system_sid, "S-1-5-18",
|
MKSID (well_known_system_sid, "S-1-5-18",
|
||||||
SECURITY_NT_AUTHORITY, 1, SECURITY_LOCAL_SYSTEM_RID);
|
SECURITY_NT_AUTHORITY, 1, SECURITY_LOCAL_SYSTEM_RID);
|
||||||
SID (well_known_admins_sid, "S-1-5-32-544",
|
MKSID (well_known_admins_sid, "S-1-5-32-544",
|
||||||
SECURITY_NT_AUTHORITY, 2, SECURITY_BUILTIN_DOMAIN_RID,
|
SECURITY_NT_AUTHORITY, 2, SECURITY_BUILTIN_DOMAIN_RID,
|
||||||
DOMAIN_ALIAS_RID_ADMINS);
|
DOMAIN_ALIAS_RID_ADMINS);
|
||||||
|
|
||||||
#define SECURITY_MANDATORY_INTEGRITY_AUTHORITY {0,0,0,0,0,16}
|
#define SECURITY_MANDATORY_INTEGRITY_AUTHORITY {0,0,0,0,0,16}
|
||||||
|
|
||||||
SID (mandatory_medium_integrity_sid, "S-1-64-8192",
|
MKSID (mandatory_medium_integrity_sid, "S-1-64-8192",
|
||||||
SECURITY_MANDATORY_INTEGRITY_AUTHORITY, 1, 8192);
|
SECURITY_MANDATORY_INTEGRITY_AUTHORITY, 1, 8192);
|
||||||
SID (mandatory_high_integrity_sid, "S-1-64-12288",
|
MKSID (mandatory_high_integrity_sid, "S-1-64-12288",
|
||||||
SECURITY_MANDATORY_INTEGRITY_AUTHORITY, 1, 12288);
|
SECURITY_MANDATORY_INTEGRITY_AUTHORITY, 1, 12288);
|
||||||
SID (mandatory_system_integrity_sid, "S-1-64-16384",
|
MKSID (mandatory_system_integrity_sid, "S-1-64-16384",
|
||||||
SECURITY_MANDATORY_INTEGRITY_AUTHORITY, 1, 16384);
|
SECURITY_MANDATORY_INTEGRITY_AUTHORITY, 1, 16384);
|
||||||
|
|
||||||
bool
|
bool
|
||||||
cygpsid::operator== (const char *nsidstr) const
|
cygpsid::operator== (const char *nsidstr) const
|
||||||
|
|
|
@ -23,8 +23,16 @@ details. */
|
||||||
#define ACL_DEFAULT_SIZE 3072
|
#define ACL_DEFAULT_SIZE 3072
|
||||||
#define NO_SID ((PSID)NULL)
|
#define NO_SID ((PSID)NULL)
|
||||||
|
|
||||||
|
/* Added for debugging purposes. */
|
||||||
|
typedef struct {
|
||||||
|
BYTE Revision;
|
||||||
|
BYTE SubAuthorityCount;
|
||||||
|
SID_IDENTIFIER_AUTHORITY IdentifierAuthority;
|
||||||
|
DWORD SubAuthority[8];
|
||||||
|
} DBGSID, *PDBGSID;
|
||||||
|
|
||||||
/* Macro to define variable length SID structures */
|
/* Macro to define variable length SID structures */
|
||||||
#define SID(name, comment, authority, count, rid...) \
|
#define MKSID(name, comment, authority, count, rid...) \
|
||||||
static NO_COPY struct { \
|
static NO_COPY struct { \
|
||||||
BYTE Revision; \
|
BYTE Revision; \
|
||||||
BYTE SubAuthorityCount; \
|
BYTE SubAuthorityCount; \
|
||||||
|
|
Loading…
Reference in New Issue