📄 jclwin32.pas
字号:
VER_SUITE_SECURITY_APPLIANCE = $00001000;
{$EXTERNALSYM VER_SUITE_SECURITY_APPLIANCE}
// line 515
//
// A language ID is a 16 bit value which is the combination of a
// primary language ID and a secondary language ID. The bits are
// allocated as follows:
//
// +-----------------------+-------------------------+
// | Sublanguage ID | Primary Language ID |
// +-----------------------+-------------------------+
// 15 10 9 0 bit
//
//
// Language ID creation/extraction macros:
//
// MAKELANGID - construct language id from a primary language id and
// a sublanguage id.
// PRIMARYLANGID - extract primary language id from a language id.
// SUBLANGID - extract sublanguage id from a language id.
//
function MAKELANGID(PrimaryLang, SubLang: USHORT): WORD;
{$EXTERNALSYM MAKELANGID}
function PRIMARYLANGID(LangId: WORD): WORD;
{$EXTERNALSYM PRIMARYLANGID}
function SUBLANGID(LangId: WORD): WORD;
{$EXTERNALSYM SUBLANGID}
//
// A locale ID is a 32 bit value which is the combination of a
// language ID, a sort ID, and a reserved area. The bits are
// allocated as follows:
//
// +-------------+---------+-------------------------+
// | Reserved | Sort ID | Language ID |
// +-------------+---------+-------------------------+
// 31 20 19 16 15 0 bit
//
//
// Locale ID creation/extraction macros:
//
// MAKELCID - construct the locale id from a language id and a sort id.
// MAKESORTLCID - construct the locale id from a language id, sort id, and sort version.
// LANGIDFROMLCID - extract the language id from a locale id.
// SORTIDFROMLCID - extract the sort id from a locale id.
// SORTVERSIONFROMLCID - extract the sort version from a locale id.
//
const
NLS_VALID_LOCALE_MASK = $000fffff;
{$EXTERNALSYM NLS_VALID_LOCALE_MASK}
function MAKELCID(LangId, SortId: WORD): DWORD;
{$EXTERNALSYM MAKELCID}
function MAKESORTLCID(LangId, SortId, SortVersion: WORD): DWORD;
{$EXTERNALSYM MAKESORTLCID}
function LANGIDFROMLCID(LocaleId: LCID): WORD;
{$EXTERNALSYM LANGIDFROMLCID}
function SORTIDFROMLCID(LocaleId: LCID): WORD;
{$EXTERNALSYM SORTIDFROMLCID}
function SORTVERSIONFROMLCID(LocaleId: LCID): WORD;
{$EXTERNALSYM SORTVERSIONFROMLCID}
// line 1154
////////////////////////////////////////////////////////////////////////
// //
// Security Id (SID) //
// //
////////////////////////////////////////////////////////////////////////
//
//
// Pictorially the structure of an SID is as follows:
//
// 1 1 1 1 1 1
// 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0
// +---------------------------------------------------------------+
// | SubAuthorityCount |Reserved1 (SBZ)| Revision |
// +---------------------------------------------------------------+
// | IdentifierAuthority[0] |
// +---------------------------------------------------------------+
// | IdentifierAuthority[1] |
// +---------------------------------------------------------------+
// | IdentifierAuthority[2] |
// +---------------------------------------------------------------+
// | |
// +- - - - - - - - SubAuthority[] - - - - - - - - -+
// | |
// +---------------------------------------------------------------+
//
//
type
// PSid = ^SID;
_SID = record
Revision: Byte;
SubAuthorityCount: Byte;
IdentifierAuthority: SID_IDENTIFIER_AUTHORITY;
SubAuthority: array [0..ANYSIZE_ARRAY - 1] of DWORD;
end;
{$EXTERNALSYM _SID}
SID = _SID;
{$EXTERNALSYM SID}
PPSID = ^PSID;
{$NODEFINE PPSID}
TSid = SID;
const
SID_REVISION = (1); // Current revision level
{$EXTERNALSYM SID_REVISION}
SID_MAX_SUB_AUTHORITIES = (15);
{$EXTERNALSYM SID_MAX_SUB_AUTHORITIES}
SID_RECOMMENDED_SUB_AUTHORITIES = (1); // Will change to around 6 in a future release.
{$EXTERNALSYM SID_RECOMMENDED_SUB_AUTHORITIES}
SECURITY_MAX_SID_SIZE = SizeOf(SID) - SizeOf(DWORD) + (SID_MAX_SUB_AUTHORITIES * SizeOf(DWORD));
{$EXTERNALSYM SECURITY_MAX_SID_SIZE}
SidTypeUser = 1;
{$EXTERNALSYM SidTypeUser}
SidTypeGroup = 2;
{$EXTERNALSYM SidTypeGroup}
SidTypeDomain = 3;
{$EXTERNALSYM SidTypeDomain}
SidTypeAlias = 4;
{$EXTERNALSYM SidTypeAlias}
SidTypeWellKnownGroup = 5;
{$EXTERNALSYM SidTypeWellKnownGroup}
SidTypeDeletedAccount = 6;
{$EXTERNALSYM SidTypeDeletedAccount}
SidTypeInvalid = 7;
{$EXTERNALSYM SidTypeInvalid}
SidTypeUnknown = 8;
{$EXTERNALSYM SidTypeUnknown}
SidTypeComputer = 9;
{$EXTERNALSYM SidTypeComputer}
type
_SID_NAME_USE = DWORD;
{$EXTERNALSYM _SID_NAME_USE}
// SID_NAME_USE = _SID_NAME_USE;
// {$EXTERNALSYM SID_NAME_USE}
PSID_NAME_USE = ^SID_NAME_USE;
{$EXTERNALSYM PSID_NAME_USE}
TSidNameUse = SID_NAME_USE;
PSidNameUSe = PSID_NAME_USE;
PSID_AND_ATTRIBUTES = ^SID_AND_ATTRIBUTES;
{$EXTERNALSYM PSID_AND_ATTRIBUTES}
_SID_AND_ATTRIBUTES = record
Sid: PSID;
Attributes: DWORD;
end;
{$EXTERNALSYM _SID_AND_ATTRIBUTES}
SID_AND_ATTRIBUTES = _SID_AND_ATTRIBUTES;
{$EXTERNALSYM SID_AND_ATTRIBUTES}
TSidAndAttributes = SID_AND_ATTRIBUTES;
PSidAndAttributes = PSID_AND_ATTRIBUTES;
SID_AND_ATTRIBUTES_ARRAY = array [0..ANYSIZE_ARRAY - 1] of SID_AND_ATTRIBUTES;
{$EXTERNALSYM SID_AND_ATTRIBUTES_ARRAY}
PSID_AND_ATTRIBUTES_ARRAY = ^SID_AND_ATTRIBUTES_ARRAY;
{$EXTERNALSYM PSID_AND_ATTRIBUTES_ARRAY}
PSidAndAttributesArray = ^TSidAndAttributesArray;
TSidAndAttributesArray = SID_AND_ATTRIBUTES_ARRAY;
/////////////////////////////////////////////////////////////////////////////
// //
// Universal well-known SIDs //
// //
// Null SID S-1-0-0 //
// World S-1-1-0 //
// Local S-1-2-0 //
// Creator Owner ID S-1-3-0 //
// Creator Group ID S-1-3-1 //
// Creator Owner Server ID S-1-3-2 //
// Creator Group Server ID S-1-3-3 //
// //
// (Non-unique IDs) S-1-4 //
// //
/////////////////////////////////////////////////////////////////////////////
const
SECURITY_NULL_SID_AUTHORITY: TSidIdentifierAuthority = (Value: (0, 0, 0, 0, 0, 0));
{$EXTERNALSYM SECURITY_NULL_SID_AUTHORITY}
SECURITY_WORLD_SID_AUTHORITY: TSidIdentifierAuthority = (Value: (0, 0, 0, 0, 0, 1));
{$EXTERNALSYM SECURITY_WORLD_SID_AUTHORITY}
SECURITY_LOCAL_SID_AUTHORITY: TSidIdentifierAuthority = (Value: (0, 0, 0, 0, 0, 2));
{$EXTERNALSYM SECURITY_LOCAL_SID_AUTHORITY}
SECURITY_CREATOR_SID_AUTHORITY: TSidIdentifierAuthority = (Value: (0, 0, 0, 0, 0, 3));
{$EXTERNALSYM SECURITY_CREATOR_SID_AUTHORITY}
SECURITY_NON_UNIQUE_AUTHORITY: TSidIdentifierAuthority = (Value: (0, 0, 0, 0, 0, 4));
{$EXTERNALSYM SECURITY_NON_UNIQUE_AUTHORITY}
SECURITY_RESOURCE_MANAGER_AUTHORITY: TSidIdentifierAuthority = (Value: (0, 0, 0, 0, 0, 9));
{$EXTERNALSYM SECURITY_RESOURCE_MANAGER_AUTHORITY}
SECURITY_NULL_RID = ($00000000);
{$EXTERNALSYM SECURITY_NULL_RID}
SECURITY_WORLD_RID = ($00000000);
{$EXTERNALSYM SECURITY_WORLD_RID}
SECURITY_LOCAL_RID = ($00000000);
{$EXTERNALSYM SECURITY_LOCAL_RID}
SECURITY_CREATOR_OWNER_RID = ($00000000);
{$EXTERNALSYM SECURITY_CREATOR_OWNER_RID}
SECURITY_CREATOR_GROUP_RID = ($00000001);
{$EXTERNALSYM SECURITY_CREATOR_GROUP_RID}
SECURITY_CREATOR_OWNER_SERVER_RID = ($00000002);
{$EXTERNALSYM SECURITY_CREATOR_OWNER_SERVER_RID}
SECURITY_CREATOR_GROUP_SERVER_RID = ($00000003);
{$EXTERNALSYM SECURITY_CREATOR_GROUP_SERVER_RID}
/////////////////////////////////////////////////////////////////////////////
// //
// NT well-known SIDs //
// //
// NT Authority S-1-5 //
// Dialup S-1-5-1 //
// //
// Network S-1-5-2 //
// Batch S-1-5-3 //
// Interactive S-1-5-4 //
// (Logon IDs) S-1-5-5-X-Y //
// Service S-1-5-6 //
// AnonymousLogon S-1-5-7 (aka null logon session) //
// Proxy S-1-5-8 //
// Enterprise DC (EDC) S-1-5-9 (aka domain controller account) //
// Self S-1-5-10 (self RID) //
// Authenticated User S-1-5-11 (Authenticated user somewhere) //
// Restricted Code S-1-5-12 (Running restricted code) //
// Terminal Server S-1-5-13 (Running on Terminal Server) //
// Remote Logon S-1-5-14 (Remote Interactive Logon) //
// This Organization S-1-5-15 //
// //
// Local System S-1-5-18 //
// Local Service S-1-5-19 //
// Network Service S-1-5-20 //
// //
// (NT non-unique IDs) S-1-5-0x15-... (NT Domain Sids) //
// //
// (Built-in domain) S-1-5-0x20 //
// //
// (Security Package IDs) S-1-5-0x40 //
// NTLM Authentication S-1-5-0x40-10 //
// SChannel Authentication S-1-5-0x40-14 //
// Digest Authentication S-1-5-0x40-21 //
// //
// Other Organization S-1-5-1000 (>=1000 can not be filtered) //
// //
// //
// NOTE: the relative identifier values (RIDs) determine which security //
// boundaries the SID is allowed to cross. Before adding new RIDs, //
// a determination needs to be made regarding which range they should //
// be added to in order to ensure proper "SID filtering" //
// //
/////////////////////////////////////////////////////////////////////////////
const
SECURITY_NT_AUTHORITY: TSidIdentifierAuthority = (Value: (0, 0, 0, 0, 0, 5));
{$EXTERNALSYM SECURITY_NT_AUTHORITY}
SECURITY_DIALUP_RID = ($00000001);
{$EXTERNALSYM SECURITY_DIALUP_RID}
SECURITY_NETWORK_RID = ($00000002);
{$EXTERNALSYM SECURITY_NETWORK_RID}
SECURITY_BATCH_RID = ($00000003);
{$EXTERNALSYM SECURITY_BATCH_RID}
SECURITY_INTERACTIVE_RID = ($00000004);
{$EXTERNALSYM SECURITY_INTERACTIVE_RID}
SECURITY_LOGON_IDS_RID = ($00000005);
{$EXTERNALSYM SECURITY_LOGON_IDS_RID}
SECURITY_LOGON_IDS_RID_COUNT = (3);
{$EXTERNALSYM SECURITY_LOGON_IDS_RID_COUNT}
SECURITY_SERVICE_RID = ($00000006);
{$EXTERNALSYM SECURITY_SERVICE_RID}
SECURITY_ANONYMOUS_LOGON_RID = ($00000007);
{$EXTERNALSYM SECURITY_ANONYMOUS_LOGON_RID}
SECURITY_PROXY_RID = ($00000008);
{$EXTERNALSYM SECURITY_PROXY_RID}
SECURITY_ENTERPRISE_CONTROLLERS_RID = ($00000009);
{$EXTERNALSYM SECURITY_ENTERPRISE_CONTROLLERS_RID}
SECURITY_SERVER_LOGON_RID = SECURITY_ENTERPRISE_CONTROLLERS_RID;
{$EXTERNALSYM SECURITY_SERVER_LOGON_RID}
SECURITY_PRINCIPAL_SELF_RID = ($0000000A);
{$EXTERNALSYM SECURITY_PRINCIPAL_SELF_RID}
SECURITY_AUTHENTICATED_USER_RID = ($0000000B);
{$EXTERNALSYM SECURITY_AUTHENTICATED_USER_RID}
SECURITY_RESTRICTED_CODE_RID = ($0000000C);
{$EXTERNALSYM SECURITY_RESTRICTED_CODE_RID}
SECURITY_TERMINAL_SERVER_RID = ($0000000D);
{$EXTERNALSYM SECURITY_TERMINAL_SERVER_RID}
SECURITY_REMOTE_LOGON_RID = ($0000000E);
{$EXTERNALSYM SECURITY_REMOTE_LOGON_RID}
SECURITY_THIS_ORGANIZATION_RID = ($0000000F);
{$EXTERNALSYM SECURITY_THIS_ORGANIZATION_RID}
SECURITY_LOCAL_SYSTEM_RID = ($00000012);
{$EXTERNALSYM SECURITY_LOCAL_SYSTEM_RID}
SECURITY_LOCAL_SERVICE_RID = ($00000013);
{$EXTERNALSYM SECURITY_LOCAL_SERVICE_RID}
SECURITY_NETWORK_SERVICE_RID = ($00000014);
{$EXTERNALSYM SECURITY_NETWORK_SERVICE_RID}
SECURITY_NT_NON_UNIQUE = ($00000015);
{$EXTERNALSYM SECURITY_NT_NON_UNIQUE}
SECURITY_NT_NON_UNIQUE_SUB_AUTH_COUNT = (3);
{$EXTERNALSYM SECURITY_NT_NON_UNIQUE_SUB_AUTH_COUNT}
SECURITY_BUILTIN_DOMAIN_RID = ($00000020);
{$EXTERNALSYM SECURITY_BUILTIN_DOMAIN_RID}
SECURITY_PACKAGE_BASE_RID = ($00000040);
{$EXTERNALSYM SECURITY_PACKAGE_BASE_RID}
SECURITY_PACKAGE_RID_COUNT = (2);
{$EXTERNALSYM SECURITY_PACKAGE_RID_COUNT}
SECURITY_PACKAGE_NTLM_RID = ($0000000A);
{$EXTERNALSYM SECURITY_PACKAGE_NTLM_RID}
SECURITY_PACKAGE_SCHANNEL_RID = ($0000000E);
{$EXTERNALSYM SECURITY_PACKAGE_SCHANNEL_RID}
SECURITY_PACKAGE_DIGEST_RID = ($00000015);
{$EXTERNALSYM SECURITY_PACKAGE_DIGEST_RID}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -