📄 aclapi.pas
字号:
{$EXTERNALSYM BuildTrusteeWithName}
{$ENDIF}
procedure BuildImpersonateTrusteeA(pTrustee: PTRUSTEE_A;
pImpersonateTrustee: PTRUSTEE_A); stdcall;
{$EXTERNALSYM BuildImpersonateTrusteeA}
procedure BuildImpersonateTrusteeW(pTrustee: PTRUSTEE_W;
pImpersonateTrustee: PTRUSTEE_W); stdcall;
{$EXTERNALSYM BuildImpersonateTrusteeW}
{$IFDEF UNICODE}
procedure BuildImpersonateTrustee(pTrustee: PTRUSTEE_W;
pImpersonateTrustee: PTRUSTEE_W); stdcall;
{$EXTERNALSYM BuildImpersonateTrustee}
{$ELSE}
procedure BuildImpersonateTrustee(pTrustee: PTRUSTEE_A;
pImpersonateTrustee: PTRUSTEE_A); stdcall;
{$EXTERNALSYM BuildImpersonateTrustee}
{$ENDIF}
procedure BuildTrusteeWithSidA(pTrustee: PTRUSTEE_A; pSid: PSID); stdcall;
{$EXTERNALSYM BuildTrusteeWithSidA}
procedure BuildTrusteeWithSidW(pTrustee: PTRUSTEE_W; pSid: PSID); stdcall;
{$EXTERNALSYM BuildTrusteeWithSidW}
{$IFDEF UNICODE}
procedure BuildTrusteeWithSid(pTrustee: PTRUSTEE_W; pSid: PSID); stdcall;
{$EXTERNALSYM BuildTrusteeWithSid}
{$ELSE}
procedure BuildTrusteeWithSid(pTrustee: PTRUSTEE_A; pSid: PSID); stdcall;
{$EXTERNALSYM BuildTrusteeWithSid}
{$ENDIF}
procedure BuildTrusteeWithObjectsAndSidA(pTrustee: PTRUSTEE_A;
pObjSid: POBJECTS_AND_SID; pObjectGuid: PGUID; pInheritedObjectGuid: PGUID;
pSid: PSID); stdcall;
{$EXTERNALSYM BuildTrusteeWithObjectsAndSidA}
procedure BuildTrusteeWithObjectsAndSidW(pTrustee: PTRUSTEE_W;
pObjSid: POBJECTS_AND_SID; pObjectGuid: PGUID; pInheritedObjectGuid: PGUID;
pSid: PSID); stdcall;
{$EXTERNALSYM BuildTrusteeWithObjectsAndSidW}
{$IFDEF UNICODE}
procedure BuildTrusteeWithObjectsAndSid(pTrustee: PTRUSTEE_W;
pObjSid: POBJECTS_AND_SID; pObjectGuid: PGUID; pInheritedObjectGuid: PGUID;
pSid: PSID); stdcall;
{$EXTERNALSYM BuildTrusteeWithObjectsAndSid}
{$ELSE}
procedure BuildTrusteeWithObjectsAndSid(pTrustee: PTRUSTEE_A;
pObjSid: POBJECTS_AND_SID; pObjectGuid: PGUID; pInheritedObjectGuid: PGUID;
pSid: PSID); stdcall;
{$EXTERNALSYM BuildTrusteeWithObjectsAndSid}
{$ENDIF}
procedure BuildTrusteeWithObjectsAndNameA(pTrustee: PTRUSTEE_A;
pObjName: POBJECTS_AND_NAME_A; ObjectType: SE_OBJECT_TYPE;
ObjectTypeName, InheritedObjectTypeName, Name: LPSTR); stdcall;
{$EXTERNALSYM BuildTrusteeWithObjectsAndNameA}
procedure BuildTrusteeWithObjectsAndNameW(pTrustee: PTRUSTEE_W;
pObjName: POBJECTS_AND_NAME_W; ObjectType: SE_OBJECT_TYPE;
ObjectTypeName, InheritedObjectTypeName, Name: LPWSTR); stdcall;
{$EXTERNALSYM BuildTrusteeWithObjectsAndNameW}
{$IFDEF UNICODE}
procedure BuildTrusteeWithObjectsAndName(pTrustee: PTRUSTEE_W;
pObjName: POBJECTS_AND_NAME_W; ObjectType: SE_OBJECT_TYPE;
ObjectTypeName, InheritedObjectTypeName, Name: LPWSTR); stdcall;
{$EXTERNALSYM BuildTrusteeWithObjectsAndName}
{$ELSE}
procedure BuildTrusteeWithObjectsAndName(pTrustee: PTRUSTEE_A;
pObjName: POBJECTS_AND_NAME_A; ObjectType: SE_OBJECT_TYPE;
ObjectTypeName, InheritedObjectTypeName, Name: LPSTR); stdcall;
{$EXTERNALSYM BuildTrusteeWithObjectsAndName}
{$ENDIF}
function GetTrusteeNameA(pTrustee: PTRUSTEE_A): LPSTR; stdcall;
{$EXTERNALSYM GetTrusteeNameA}
function GetTrusteeNameW(pTrustee: PTRUSTEE_W): LPWSTR; stdcall;
{$EXTERNALSYM GetTrusteeNameW}
{$IFDEF UNICODE}
function GetTrusteeName(pTrustee: PTRUSTEE_W): LPWSTR; stdcall;
{$EXTERNALSYM GetTrusteeName}
{$ELSE}
function GetTrusteeName(pTrustee: PTRUSTEE_A): LPSTR; stdcall;
{$EXTERNALSYM GetTrusteeName}
{$ENDIF}
function GetTrusteeTypeA(pTrustee: PTRUSTEE_A): TRUSTEE_TYPE; stdcall;
{$EXTERNALSYM GetTrusteeTypeA}
function GetTrusteeTypeW(pTrustee: PTRUSTEE_W): TRUSTEE_TYPE; stdcall;
{$EXTERNALSYM GetTrusteeTypeW}
{$IFDEF UNICODE}
function GetTrusteeType(pTrustee: PTRUSTEE_W): TRUSTEE_TYPE; stdcall;
{$EXTERNALSYM GetTrusteeType}
{$ELSE}
function GetTrusteeType(pTrustee: PTRUSTEE_A): TRUSTEE_TYPE; stdcall;
{$EXTERNALSYM GetTrusteeType}
{$ENDIF}
function GetTrusteeFormA(pTrustee: PTRUSTEE_A): TRUSTEE_FORM; stdcall;
{$EXTERNALSYM GetTrusteeFormA}
function GetTrusteeFormW(pTrustee: PTRUSTEE_W): TRUSTEE_FORM; stdcall;
{$EXTERNALSYM GetTrusteeFormW}
{$IFDEF UNICODE}
function GetTrusteeForm(pTrustee: PTRUSTEE_W): TRUSTEE_FORM; stdcall;
{$EXTERNALSYM GetTrusteeForm}
{$ELSE}
function GetTrusteeForm(pTrustee: PTRUSTEE_A): TRUSTEE_FORM; stdcall;
{$EXTERNALSYM GetTrusteeForm}
{$ENDIF}
function GetMultipleTrusteeOperationA(pTrustee: PTRUSTEE_A): MULTIPLE_TRUSTEE_OPERATION; stdcall;
{$EXTERNALSYM GetMultipleTrusteeOperationA}
function GetMultipleTrusteeOperationW(pTrustee: PTRUSTEE_W): MULTIPLE_TRUSTEE_OPERATION; stdcall;
{$EXTERNALSYM GetMultipleTrusteeOperationW}
{$IFDEF UNICODE}
function GetMultipleTrusteeOperation(pTrustee: PTRUSTEE_W): MULTIPLE_TRUSTEE_OPERATION; stdcall;
{$EXTERNALSYM GetMultipleTrusteeOperation}
{$ELSE}
function GetMultipleTrusteeOperation(pTrustee: PTRUSTEE_A): MULTIPLE_TRUSTEE_OPERATION; stdcall;
{$EXTERNALSYM GetMultipleTrusteeOperation}
{$ENDIF}
function GetMultipleTrusteeA(pTrustee: PTRUSTEE_A): PTRUSTEE_A; stdcall;
{$EXTERNALSYM GetMultipleTrusteeA}
function GetMultipleTrusteeW(pTrustee: PTRUSTEE_W): PTRUSTEE_W; stdcall;
{$EXTERNALSYM GetMultipleTrusteeW}
{$IFDEF UNICODE}
function GetMultipleTrustee(pTrustee: PTRUSTEE_W): PTRUSTEE_W; stdcall;
{$EXTERNALSYM GetMultipleTrustee}
{$ELSE}
function GetMultipleTrustee(pTrustee: PTRUSTEE_A): PTRUSTEE_A; stdcall;
{$EXTERNALSYM GetMultipleTrustee}
{$ENDIF}
implementation
const
aclapilib = 'advapi32.dll';
function SetEntriesInAclA; external aclapilib name 'SetEntriesInAclA';
function SetEntriesInAclW; external aclapilib name 'SetEntriesInAclW';
{$IFDEF UNICODE}
function SetEntriesInAcl; external aclapilib name 'SetEntriesInAclW';
{$ELSE}
function SetEntriesInAcl; external aclapilib name 'SetEntriesInAclA';
{$ENDIF}
function GetExplicitEntriesFromAclA; external aclapilib name 'GetExplicitEntriesFromAclA';
function GetExplicitEntriesFromAclW; external aclapilib name 'GetExplicitEntriesFromAclW';
{$IFDEF UNICODE}
function GetExplicitEntriesFromAcl; external aclapilib name 'GetExplicitEntriesFromAclW';
{$ELSE}
function GetExplicitEntriesFromAcl; external aclapilib name 'GetExplicitEntriesFromAclA';
{$ENDIF}
function GetEffectiveRightsFromAclA; external aclapilib name 'GetEffectiveRightsFromAclA';
function GetEffectiveRightsFromAclW; external aclapilib name 'GetEffectiveRightsFromAclW';
{$IFDEF UNICODE}
function GetEffectiveRightsFromAcl; external aclapilib name 'GetEffectiveRightsFromAclW';
{$ELSE}
function GetEffectiveRightsFromAcl; external aclapilib name 'GetEffectiveRightsFromAclA';
{$ENDIF}
function GetAuditedPermissionsFromAclA; external aclapilib name 'GetAuditedPermissionsFromAclA';
function GetAuditedPermissionsFromAclW; external aclapilib name 'GetAuditedPermissionsFromAclW';
{$IFDEF UNICODE}
function GetAuditedPermissionsFromAcl; external aclapilib name 'GetAuditedPermissionsFromAclW';
{$ELSE}
function GetAuditedPermissionsFromAcl; external aclapilib name 'GetAuditedPermissionsFromAclA';
{$ENDIF}
function GetNamedSecurityInfoA; external aclapilib name 'GetNamedSecurityInfoA';
function GetNamedSecurityInfoW; external aclapilib name 'GetNamedSecurityInfoW';
{$IFDEF UNICODE}
function GetNamedSecurityInfo; external aclapilib name 'GetNamedSecurityInfoW';
{$ELSE}
function GetNamedSecurityInfo; external aclapilib name 'GetNamedSecurityInfoA';
{$ENDIF}
function GetSecurityInfo; external aclapilib name 'GetSecurityInfo';
function SetNamedSecurityInfoA; external aclapilib name 'SetNamedSecurityInfoA';
function SetNamedSecurityInfoW; external aclapilib name 'SetNamedSecurityInfoW';
{$IFDEF UNICODE}
function SetNamedSecurityInfo; external aclapilib name 'SetNamedSecurityInfoW';
{$ELSE}
function SetNamedSecurityInfo; external aclapilib name 'SetNamedSecurityInfoA';
{$ENDIF}
function SetSecurityInfo; external aclapilib name 'SetSecurityInfo';
function BuildSecurityDescriptorA; external aclapilib name 'BuildSecurityDescriptorA';
function BuildSecurityDescriptorW; external aclapilib name 'BuildSecurityDescriptorW';
{$IFDEF UNICODE}
function BuildSecurityDescriptor; external aclapilib name 'BuildSecurityDescriptorW';
{$ELSE}
function BuildSecurityDescriptor; external aclapilib name 'BuildSecurityDescriptorA';
{$ENDIF}
function LookupSecurityDescriptorPartsA; external aclapilib name 'LookupSecurityDescriptorPartsA';
function LookupSecurityDescriptorPartsW; external aclapilib name 'LookupSecurityDescriptorPartsW';
{$IFDEF UNICODE}
function LookupSecurityDescriptorParts; external aclapilib name 'LookupSecurityDescriptorPartsW';
{$ELSE}
function LookupSecurityDescriptorParts; external aclapilib name 'LookupSecurityDescriptorPartsA';
{$ENDIF}
procedure BuildExplicitAccessWithNameA; external aclapilib name 'BuildExplicitAccessWithNameA';
procedure BuildExplicitAccessWithNameW; external aclapilib name 'BuildExplicitAccessWithNameW';
{$IFDEF UNICODE}
procedure BuildExplicitAccessWithName; external aclapilib name 'BuildExplicitAccessWithNameW';
{$ELSE}
procedure BuildExplicitAccessWithName; external aclapilib name 'BuildExplicitAccessWithNameA';
{$ENDIF}
procedure BuildImpersonateExplicitAccessWithNameA; external aclapilib name 'BuildImpersonateExplicitAccessWithNameA';
procedure BuildImpersonateExplicitAccessWithNameW; external aclapilib name 'BuildImpersonateExplicitAccessWithNameW';
{$IFDEF UNICODE}
procedure BuildImpersonateExplicitAccessWithName; external aclapilib name 'BuildImpersonateExplicitAccessWithNameW';
{$ELSE}
procedure BuildImpersonateExplicitAccessWithName; external aclapilib name 'BuildImpersonateExplicitAccessWithNameA';
{$ENDIF}
procedure BuildTrusteeWithNameA; external aclapilib name 'BuildTrusteeWithNameA';
procedure BuildTrusteeWithNameW; external aclapilib name 'BuildTrusteeWithNameW';
{$IFDEF UNICODE}
procedure BuildTrusteeWithName; external aclapilib name 'BuildTrusteeWithNameW';
{$ELSE}
procedure BuildTrusteeWithName; external aclapilib name 'BuildTrusteeWithNameA';
{$ENDIF}
procedure BuildImpersonateTrusteeA; external aclapilib name 'BuildImpersonateTrusteeA';
procedure BuildImpersonateTrusteeW; external aclapilib name 'BuildImpersonateTrusteeW';
{$IFDEF UNICODE}
procedure BuildImpersonateTrustee; external aclapilib name 'BuildImpersonateTrusteeW';
{$ELSE}
procedure BuildImpersonateTrustee; external aclapilib name 'BuildImpersonateTrusteeA';
{$ENDIF}
procedure BuildTrusteeWithSidA; external aclapilib name 'BuildTrusteeWithSidA';
procedure BuildTrusteeWithSidW; external aclapilib name 'BuildTrusteeWithSidW';
{$IFDEF UNICODE}
procedure BuildTrusteeWithSid; external aclapilib name 'BuildTrusteeWithSidW';
{$ELSE}
procedure BuildTrusteeWithSid; external aclapilib name 'BuildTrusteeWithSidA';
{$ENDIF}
procedure BuildTrusteeWithObjectsAndSidA; external aclapilib name 'BuildTrusteeWithObjectsAndSidA';
procedure BuildTrusteeWithObjectsAndSidW; external aclapilib name 'BuildTrusteeWithObjectsAndSidW';
{$IFDEF UNICODE}
procedure BuildTrusteeWithObjectsAndSid; external aclapilib name 'BuildTrusteeWithObjectsAndSidW';
{$ELSE}
procedure BuildTrusteeWithObjectsAndSid; external aclapilib name 'BuildTrusteeWithObjectsAndSidA';
{$ENDIF}
procedure BuildTrusteeWithObjectsAndNameA; external aclapilib name 'BuildTrusteeWithObjectsAndNameA';
procedure BuildTrusteeWithObjectsAndNameW; external aclapilib name 'BuildTrusteeWithObjectsAndNameW';
{$IFDEF UNICODE}
procedure BuildTrusteeWithObjectsAndName; external aclapilib name 'BuildTrusteeWithObjectsAndNameW';
{$ELSE}
procedure BuildTrusteeWithObjectsAndName; external aclapilib name 'BuildTrusteeWithObjectsAndNameA';
{$ENDIF}
function GetTrusteeNameA; external aclapilib name 'GetTrusteeNameA';
function GetTrusteeNameW; external aclapilib name 'GetTrusteeNameW';
{$IFDEF UNICODE}
function GetTrusteeName; external aclapilib name 'GetTrusteeNameW';
{$ELSE}
function GetTrusteeName; external aclapilib name 'GetTrusteeNameA';
{$ENDIF}
function GetTrusteeTypeA; external aclapilib name 'GetTrusteeTypeA';
function GetTrusteeTypeW; external aclapilib name 'GetTrusteeTypeW';
{$IFDEF UNICODE}
function GetTrusteeType; external aclapilib name 'GetTrusteeTypeW';
{$ELSE}
function GetTrusteeType; external aclapilib name 'GetTrusteeTypeA';
{$ENDIF}
function GetTrusteeFormA; external aclapilib name 'GetTrusteeFormA';
function GetTrusteeFormW; external aclapilib name 'GetTrusteeFormW';
{$IFDEF UNICODE}
function GetTrusteeForm; external aclapilib name 'GetTrusteeFormW';
{$ELSE}
function GetTrusteeForm; external aclapilib name 'GetTrusteeFormA';
{$ENDIF}
function GetMultipleTrusteeOperationA; external aclapilib name 'GetMultipleTrusteeOperationA';
function GetMultipleTrusteeOperationW; external aclapilib name 'GetMultipleTrusteeOperationW';
{$IFDEF UNICODE}
function GetMultipleTrusteeOperation; external aclapilib name 'GetMultipleTrusteeOperationW';
{$ELSE}
function GetMultipleTrusteeOperation; external aclapilib name 'GetMultipleTrusteeOperationA';
{$ENDIF}
function GetMultipleTrusteeA; external aclapilib name 'GetMultipleTrusteeA';
function GetMultipleTrusteeW; external aclapilib name 'GetMultipleTrusteeW';
{$IFDEF UNICODE}
function GetMultipleTrustee; external aclapilib name 'GetMultipleTrusteeW';
{$ELSE}
function GetMultipleTrustee; external aclapilib name 'GetMultipleTrusteeA';
{$ENDIF}
end.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -