2013-03-16 20:41:13 +00:00
|
|
|
/*
|
2004-12-11 00:21:33 +00:00
|
|
|
* COPYRIGHT: See COPYING in the top level directory
|
|
|
|
* PROJECT: ReactOS system libraries
|
2004-12-12 15:17:38 +00:00
|
|
|
* FILE: lib/advapi32/sec/trustee.c
|
|
|
|
* PURPOSE: Trustee functions
|
2004-12-11 00:21:33 +00:00
|
|
|
*/
|
|
|
|
|
2005-08-05 10:31:28 +00:00
|
|
|
#include <advapi32.h>
|
2008-02-08 17:04:39 +00:00
|
|
|
WINE_DEFAULT_DEBUG_CHANNEL(advapi);
|
2004-12-11 00:21:33 +00:00
|
|
|
|
|
|
|
|
2004-12-15 12:29:36 +00:00
|
|
|
/******************************************************************************
|
|
|
|
* BuildImpersonateTrusteeA [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
VOID WINAPI
|
|
|
|
BuildImpersonateTrusteeA(PTRUSTEE_A pTrustee,
|
|
|
|
PTRUSTEE_A pImpersonateTrustee)
|
|
|
|
{
|
2008-09-21 13:55:53 +00:00
|
|
|
pTrustee->pMultipleTrustee = pImpersonateTrustee;
|
|
|
|
pTrustee->MultipleTrusteeOperation = TRUSTEE_IS_IMPERSONATE;
|
2004-12-15 12:29:36 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************
|
|
|
|
* BuildImpersonateTrusteeW [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
VOID WINAPI
|
|
|
|
BuildImpersonateTrusteeW(PTRUSTEE_W pTrustee,
|
|
|
|
PTRUSTEE_W pImpersonateTrustee)
|
|
|
|
{
|
2008-09-21 13:55:53 +00:00
|
|
|
pTrustee->pMultipleTrustee = pImpersonateTrustee;
|
|
|
|
pTrustee->MultipleTrusteeOperation = TRUSTEE_IS_IMPERSONATE;
|
2004-12-15 12:29:36 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
2005-01-04 09:35:28 +00:00
|
|
|
/******************************************************************************
|
|
|
|
* BuildExplicitAccessWithNameA [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
VOID WINAPI
|
|
|
|
BuildExplicitAccessWithNameA(PEXPLICIT_ACCESSA pExplicitAccess,
|
|
|
|
LPSTR pTrusteeName,
|
|
|
|
DWORD AccessPermissions,
|
|
|
|
ACCESS_MODE AccessMode,
|
|
|
|
DWORD Inheritance)
|
|
|
|
{
|
|
|
|
pExplicitAccess->grfAccessPermissions = AccessPermissions;
|
|
|
|
pExplicitAccess->grfAccessMode = AccessMode;
|
|
|
|
pExplicitAccess->grfInheritance = Inheritance;
|
|
|
|
|
|
|
|
pExplicitAccess->Trustee.pMultipleTrustee = NULL;
|
|
|
|
pExplicitAccess->Trustee.MultipleTrusteeOperation = NO_MULTIPLE_TRUSTEE;
|
|
|
|
pExplicitAccess->Trustee.TrusteeForm = TRUSTEE_IS_NAME;
|
|
|
|
pExplicitAccess->Trustee.TrusteeType = TRUSTEE_IS_UNKNOWN;
|
|
|
|
pExplicitAccess->Trustee.ptstrName = pTrusteeName;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************
|
|
|
|
* BuildExplicitAccessWithNameW [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
VOID WINAPI
|
|
|
|
BuildExplicitAccessWithNameW(PEXPLICIT_ACCESSW pExplicitAccess,
|
|
|
|
LPWSTR pTrusteeName,
|
|
|
|
DWORD AccessPermissions,
|
|
|
|
ACCESS_MODE AccessMode,
|
|
|
|
DWORD Inheritance)
|
|
|
|
{
|
|
|
|
pExplicitAccess->grfAccessPermissions = AccessPermissions;
|
|
|
|
pExplicitAccess->grfAccessMode = AccessMode;
|
|
|
|
pExplicitAccess->grfInheritance = Inheritance;
|
|
|
|
|
|
|
|
pExplicitAccess->Trustee.pMultipleTrustee = NULL;
|
|
|
|
pExplicitAccess->Trustee.MultipleTrusteeOperation = NO_MULTIPLE_TRUSTEE;
|
|
|
|
pExplicitAccess->Trustee.TrusteeForm = TRUSTEE_IS_NAME;
|
|
|
|
pExplicitAccess->Trustee.TrusteeType = TRUSTEE_IS_UNKNOWN;
|
|
|
|
pExplicitAccess->Trustee.ptstrName = pTrusteeName;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************
|
|
|
|
* BuildImpersonateExplicitAccessWithNameA [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
VOID WINAPI
|
|
|
|
BuildImpersonateExplicitAccessWithNameA(PEXPLICIT_ACCESS_A pExplicitAccess,
|
|
|
|
LPSTR pTrusteeName,
|
|
|
|
PTRUSTEE_A pTrustee,
|
|
|
|
DWORD AccessPermissions,
|
|
|
|
ACCESS_MODE AccessMode,
|
|
|
|
DWORD Inheritance)
|
|
|
|
{
|
|
|
|
pExplicitAccess->grfAccessPermissions = AccessPermissions;
|
|
|
|
pExplicitAccess->grfAccessMode = AccessMode;
|
|
|
|
pExplicitAccess->grfInheritance = Inheritance;
|
|
|
|
|
|
|
|
pExplicitAccess->Trustee.pMultipleTrustee = pTrustee;
|
|
|
|
pExplicitAccess->Trustee.MultipleTrusteeOperation = TRUSTEE_IS_IMPERSONATE;
|
|
|
|
pExplicitAccess->Trustee.TrusteeForm = TRUSTEE_IS_NAME;
|
|
|
|
pExplicitAccess->Trustee.TrusteeType = TRUSTEE_IS_UNKNOWN;
|
|
|
|
pExplicitAccess->Trustee.ptstrName = pTrusteeName;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************
|
|
|
|
* BuildImpersonateExplicitAccessWithNameW [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
VOID WINAPI
|
|
|
|
BuildImpersonateExplicitAccessWithNameW(PEXPLICIT_ACCESS_W pExplicitAccess,
|
|
|
|
LPWSTR pTrusteeName,
|
|
|
|
PTRUSTEE_W pTrustee,
|
|
|
|
DWORD AccessPermissions,
|
|
|
|
ACCESS_MODE AccessMode,
|
|
|
|
DWORD Inheritance)
|
|
|
|
{
|
|
|
|
pExplicitAccess->grfAccessPermissions = AccessPermissions;
|
|
|
|
pExplicitAccess->grfAccessMode = AccessMode;
|
|
|
|
pExplicitAccess->grfInheritance = Inheritance;
|
|
|
|
|
|
|
|
pExplicitAccess->Trustee.pMultipleTrustee = pTrustee;
|
|
|
|
pExplicitAccess->Trustee.MultipleTrusteeOperation = TRUSTEE_IS_IMPERSONATE;
|
|
|
|
pExplicitAccess->Trustee.TrusteeForm = TRUSTEE_IS_NAME;
|
|
|
|
pExplicitAccess->Trustee.TrusteeType = TRUSTEE_IS_UNKNOWN;
|
|
|
|
pExplicitAccess->Trustee.ptstrName = pTrusteeName;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2004-12-11 00:21:33 +00:00
|
|
|
/******************************************************************************
|
|
|
|
* BuildTrusteeWithSidA [ADVAPI32.@]
|
|
|
|
*/
|
2004-12-15 12:29:36 +00:00
|
|
|
VOID WINAPI
|
2008-09-21 13:55:53 +00:00
|
|
|
BuildTrusteeWithSidA(PTRUSTEE_A pTrustee,
|
|
|
|
PSID pSid)
|
2004-12-11 00:21:33 +00:00
|
|
|
{
|
2008-02-08 17:04:39 +00:00
|
|
|
TRACE("%p %p\n", pTrustee, pSid);
|
2004-12-11 00:21:33 +00:00
|
|
|
|
|
|
|
pTrustee->pMultipleTrustee = NULL;
|
|
|
|
pTrustee->MultipleTrusteeOperation = NO_MULTIPLE_TRUSTEE;
|
|
|
|
pTrustee->TrusteeForm = TRUSTEE_IS_SID;
|
|
|
|
pTrustee->TrusteeType = TRUSTEE_IS_UNKNOWN;
|
|
|
|
pTrustee->ptstrName = (LPSTR) pSid;
|
|
|
|
}
|
|
|
|
|
2004-12-12 15:17:38 +00:00
|
|
|
|
2004-12-11 00:21:33 +00:00
|
|
|
/******************************************************************************
|
|
|
|
* BuildTrusteeWithSidW [ADVAPI32.@]
|
|
|
|
*/
|
2004-12-15 12:29:36 +00:00
|
|
|
VOID WINAPI
|
2008-09-21 13:55:53 +00:00
|
|
|
BuildTrusteeWithSidW(PTRUSTEE_W pTrustee,
|
|
|
|
PSID pSid)
|
2004-12-11 00:21:33 +00:00
|
|
|
{
|
2008-02-08 17:04:39 +00:00
|
|
|
TRACE("%p %p\n", pTrustee, pSid);
|
2004-12-11 00:21:33 +00:00
|
|
|
|
|
|
|
pTrustee->pMultipleTrustee = NULL;
|
|
|
|
pTrustee->MultipleTrusteeOperation = NO_MULTIPLE_TRUSTEE;
|
|
|
|
pTrustee->TrusteeForm = TRUSTEE_IS_SID;
|
|
|
|
pTrustee->TrusteeType = TRUSTEE_IS_UNKNOWN;
|
|
|
|
pTrustee->ptstrName = (LPWSTR) pSid;
|
|
|
|
}
|
|
|
|
|
2004-12-12 15:17:38 +00:00
|
|
|
|
2004-12-11 00:21:33 +00:00
|
|
|
/******************************************************************************
|
|
|
|
* BuildTrusteeWithNameA [ADVAPI32.@]
|
|
|
|
*/
|
2004-12-15 12:29:36 +00:00
|
|
|
VOID WINAPI
|
2008-09-21 13:55:53 +00:00
|
|
|
BuildTrusteeWithNameA(PTRUSTEE_A pTrustee,
|
|
|
|
LPSTR name)
|
2004-12-11 00:21:33 +00:00
|
|
|
{
|
2008-02-08 17:04:39 +00:00
|
|
|
TRACE("%p %s\n", pTrustee, name);
|
2004-12-11 00:21:33 +00:00
|
|
|
|
|
|
|
pTrustee->pMultipleTrustee = NULL;
|
|
|
|
pTrustee->MultipleTrusteeOperation = NO_MULTIPLE_TRUSTEE;
|
|
|
|
pTrustee->TrusteeForm = TRUSTEE_IS_NAME;
|
|
|
|
pTrustee->TrusteeType = TRUSTEE_IS_UNKNOWN;
|
|
|
|
pTrustee->ptstrName = name;
|
|
|
|
}
|
|
|
|
|
2004-12-12 15:17:38 +00:00
|
|
|
|
2004-12-11 00:21:33 +00:00
|
|
|
/******************************************************************************
|
|
|
|
* BuildTrusteeWithNameW [ADVAPI32.@]
|
|
|
|
*/
|
2004-12-15 12:29:36 +00:00
|
|
|
VOID WINAPI
|
2008-09-21 13:55:53 +00:00
|
|
|
BuildTrusteeWithNameW(PTRUSTEE_W pTrustee,
|
|
|
|
LPWSTR name)
|
2004-12-11 00:21:33 +00:00
|
|
|
{
|
2008-02-08 17:04:39 +00:00
|
|
|
TRACE("%p %s\n", pTrustee, name);
|
2004-12-11 00:21:33 +00:00
|
|
|
|
|
|
|
pTrustee->pMultipleTrustee = NULL;
|
|
|
|
pTrustee->MultipleTrusteeOperation = NO_MULTIPLE_TRUSTEE;
|
|
|
|
pTrustee->TrusteeForm = TRUSTEE_IS_NAME;
|
|
|
|
pTrustee->TrusteeType = TRUSTEE_IS_UNKNOWN;
|
|
|
|
pTrustee->ptstrName = name;
|
|
|
|
}
|
2004-12-15 12:29:36 +00:00
|
|
|
|
|
|
|
|
2005-05-05 15:39:27 +00:00
|
|
|
/******************************************************************************
|
|
|
|
* BuildTrusteeWithObjectsAndNameA [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
VOID WINAPI
|
2008-09-21 13:55:53 +00:00
|
|
|
BuildTrusteeWithObjectsAndNameA(PTRUSTEEA pTrustee,
|
|
|
|
POBJECTS_AND_NAME_A pObjName,
|
|
|
|
SE_OBJECT_TYPE ObjectType,
|
|
|
|
LPSTR ObjectTypeName,
|
|
|
|
LPSTR InheritedObjectTypeName,
|
|
|
|
LPSTR Name)
|
2005-05-05 15:39:27 +00:00
|
|
|
{
|
2006-04-20 04:28:47 +00:00
|
|
|
DWORD ObjectsPresent = 0;
|
|
|
|
|
2008-02-08 17:04:39 +00:00
|
|
|
TRACE("%p %p 0x%08x %p %p %s\n", pTrustee, pObjName,
|
2005-10-24 17:43:53 +00:00
|
|
|
ObjectType, ObjectTypeName, InheritedObjectTypeName, Name);
|
2005-05-05 15:39:27 +00:00
|
|
|
|
2006-04-20 04:28:47 +00:00
|
|
|
/* Fill the OBJECTS_AND_NAME structure */
|
|
|
|
pObjName->ObjectType = ObjectType;
|
|
|
|
if (ObjectTypeName != NULL)
|
|
|
|
{
|
|
|
|
ObjectsPresent |= ACE_OBJECT_TYPE_PRESENT;
|
|
|
|
}
|
|
|
|
|
|
|
|
pObjName->InheritedObjectTypeName = InheritedObjectTypeName;
|
|
|
|
if (InheritedObjectTypeName != NULL)
|
|
|
|
{
|
|
|
|
ObjectsPresent |= ACE_INHERITED_OBJECT_TYPE_PRESENT;
|
|
|
|
}
|
|
|
|
|
|
|
|
pObjName->ObjectsPresent = ObjectsPresent;
|
|
|
|
pObjName->ptstrName = Name;
|
|
|
|
|
|
|
|
/* Fill the TRUSTEE structure */
|
2005-05-05 15:39:27 +00:00
|
|
|
pTrustee->pMultipleTrustee = NULL;
|
|
|
|
pTrustee->MultipleTrusteeOperation = NO_MULTIPLE_TRUSTEE;
|
|
|
|
pTrustee->TrusteeForm = TRUSTEE_IS_OBJECTS_AND_NAME;
|
|
|
|
pTrustee->TrusteeType = TRUSTEE_IS_UNKNOWN;
|
2006-04-20 04:28:47 +00:00
|
|
|
pTrustee->ptstrName = (LPSTR)pObjName;
|
2005-05-05 15:39:27 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************
|
|
|
|
* BuildTrusteeWithObjectsAndNameW [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
VOID WINAPI
|
2008-09-21 13:55:53 +00:00
|
|
|
BuildTrusteeWithObjectsAndNameW(PTRUSTEEW pTrustee,
|
|
|
|
POBJECTS_AND_NAME_W pObjName,
|
|
|
|
SE_OBJECT_TYPE ObjectType,
|
|
|
|
LPWSTR ObjectTypeName,
|
|
|
|
LPWSTR InheritedObjectTypeName,
|
|
|
|
LPWSTR Name)
|
2005-05-05 15:39:27 +00:00
|
|
|
{
|
2006-04-20 04:28:47 +00:00
|
|
|
DWORD ObjectsPresent = 0;
|
|
|
|
|
2008-02-08 17:04:39 +00:00
|
|
|
TRACE("%p %p 0x%08x %p %p %s\n", pTrustee, pObjName,
|
2005-10-24 17:43:53 +00:00
|
|
|
ObjectType, ObjectTypeName, InheritedObjectTypeName, Name);
|
2005-05-05 15:39:27 +00:00
|
|
|
|
2006-04-20 04:28:47 +00:00
|
|
|
/* Fill the OBJECTS_AND_NAME structure */
|
|
|
|
pObjName->ObjectType = ObjectType;
|
|
|
|
if (ObjectTypeName != NULL)
|
|
|
|
{
|
|
|
|
ObjectsPresent |= ACE_OBJECT_TYPE_PRESENT;
|
|
|
|
}
|
|
|
|
|
|
|
|
pObjName->InheritedObjectTypeName = InheritedObjectTypeName;
|
|
|
|
if (InheritedObjectTypeName != NULL)
|
|
|
|
{
|
|
|
|
ObjectsPresent |= ACE_INHERITED_OBJECT_TYPE_PRESENT;
|
|
|
|
}
|
|
|
|
|
|
|
|
pObjName->ObjectsPresent = ObjectsPresent;
|
|
|
|
pObjName->ptstrName = Name;
|
|
|
|
|
|
|
|
/* Fill the TRUSTEE structure */
|
2005-05-05 15:39:27 +00:00
|
|
|
pTrustee->pMultipleTrustee = NULL;
|
|
|
|
pTrustee->MultipleTrusteeOperation = NO_MULTIPLE_TRUSTEE;
|
|
|
|
pTrustee->TrusteeForm = TRUSTEE_IS_OBJECTS_AND_NAME;
|
|
|
|
pTrustee->TrusteeType = TRUSTEE_IS_UNKNOWN;
|
2006-04-20 04:28:47 +00:00
|
|
|
pTrustee->ptstrName = (LPWSTR)pObjName;
|
2005-05-05 15:39:27 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************
|
|
|
|
* BuildTrusteeWithObjectsAndSidA [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
VOID WINAPI
|
2008-09-21 13:55:53 +00:00
|
|
|
BuildTrusteeWithObjectsAndSidA(PTRUSTEEA pTrustee,
|
|
|
|
POBJECTS_AND_SID pObjSid,
|
|
|
|
GUID *pObjectGuid,
|
|
|
|
GUID *pInheritedObjectGuid,
|
|
|
|
PSID pSid)
|
2005-05-05 15:39:27 +00:00
|
|
|
{
|
2006-04-20 04:28:47 +00:00
|
|
|
DWORD ObjectsPresent = 0;
|
|
|
|
|
2008-02-08 17:04:39 +00:00
|
|
|
TRACE("%p %p %p %p %p\n", pTrustee, pObjSid, pObjectGuid, pInheritedObjectGuid, pSid);
|
2005-05-05 15:39:27 +00:00
|
|
|
|
2006-04-20 04:28:47 +00:00
|
|
|
/* Fill the OBJECTS_AND_SID structure */
|
|
|
|
if (pObjectGuid != NULL)
|
|
|
|
{
|
|
|
|
pObjSid->ObjectTypeGuid = *pObjectGuid;
|
|
|
|
ObjectsPresent |= ACE_OBJECT_TYPE_PRESENT;
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
ZeroMemory(&pObjSid->ObjectTypeGuid,
|
|
|
|
sizeof(GUID));
|
|
|
|
}
|
|
|
|
|
|
|
|
if (pInheritedObjectGuid != NULL)
|
|
|
|
{
|
|
|
|
pObjSid->InheritedObjectTypeGuid = *pInheritedObjectGuid;
|
|
|
|
ObjectsPresent |= ACE_INHERITED_OBJECT_TYPE_PRESENT;
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
ZeroMemory(&pObjSid->InheritedObjectTypeGuid,
|
|
|
|
sizeof(GUID));
|
|
|
|
}
|
|
|
|
|
|
|
|
pObjSid->ObjectsPresent = ObjectsPresent;
|
|
|
|
pObjSid->pSid = pSid;
|
|
|
|
|
|
|
|
/* Fill the TRUSTEE structure */
|
2005-05-05 15:39:27 +00:00
|
|
|
pTrustee->pMultipleTrustee = NULL;
|
|
|
|
pTrustee->MultipleTrusteeOperation = NO_MULTIPLE_TRUSTEE;
|
|
|
|
pTrustee->TrusteeForm = TRUSTEE_IS_OBJECTS_AND_SID;
|
|
|
|
pTrustee->TrusteeType = TRUSTEE_IS_UNKNOWN;
|
2006-04-20 04:28:47 +00:00
|
|
|
pTrustee->ptstrName = (LPSTR) pObjSid;
|
2005-05-05 15:39:27 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************
|
|
|
|
* BuildTrusteeWithObjectsAndSidW [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
VOID WINAPI
|
2008-09-21 13:55:53 +00:00
|
|
|
BuildTrusteeWithObjectsAndSidW(PTRUSTEEW pTrustee,
|
|
|
|
POBJECTS_AND_SID pObjSid,
|
|
|
|
GUID *pObjectGuid,
|
|
|
|
GUID *pInheritedObjectGuid,
|
|
|
|
PSID pSid)
|
2005-05-05 15:39:27 +00:00
|
|
|
{
|
2006-04-20 04:28:47 +00:00
|
|
|
DWORD ObjectsPresent = 0;
|
|
|
|
|
2008-02-08 17:04:39 +00:00
|
|
|
TRACE("%p %p %p %p %p\n", pTrustee, pObjSid, pObjectGuid, pInheritedObjectGuid, pSid);
|
2005-05-05 15:39:27 +00:00
|
|
|
|
2006-04-20 04:28:47 +00:00
|
|
|
/* Fill the OBJECTS_AND_SID structure */
|
|
|
|
if (pObjectGuid != NULL)
|
|
|
|
{
|
|
|
|
pObjSid->ObjectTypeGuid = *pObjectGuid;
|
|
|
|
ObjectsPresent |= ACE_OBJECT_TYPE_PRESENT;
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
ZeroMemory(&pObjSid->ObjectTypeGuid,
|
|
|
|
sizeof(GUID));
|
|
|
|
}
|
|
|
|
|
|
|
|
if (pInheritedObjectGuid != NULL)
|
|
|
|
{
|
|
|
|
pObjSid->InheritedObjectTypeGuid = *pInheritedObjectGuid;
|
|
|
|
ObjectsPresent |= ACE_INHERITED_OBJECT_TYPE_PRESENT;
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
ZeroMemory(&pObjSid->InheritedObjectTypeGuid,
|
|
|
|
sizeof(GUID));
|
|
|
|
}
|
|
|
|
|
|
|
|
pObjSid->ObjectsPresent = ObjectsPresent;
|
|
|
|
pObjSid->pSid = pSid;
|
|
|
|
|
|
|
|
/* Fill the TRUSTEE structure */
|
2005-05-05 15:39:27 +00:00
|
|
|
pTrustee->pMultipleTrustee = NULL;
|
|
|
|
pTrustee->MultipleTrusteeOperation = NO_MULTIPLE_TRUSTEE;
|
|
|
|
pTrustee->TrusteeForm = TRUSTEE_IS_OBJECTS_AND_SID;
|
|
|
|
pTrustee->TrusteeType = TRUSTEE_IS_UNKNOWN;
|
2006-04-20 04:28:47 +00:00
|
|
|
pTrustee->ptstrName = (LPWSTR) pObjSid;
|
2005-05-05 15:39:27 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
2004-12-15 12:29:36 +00:00
|
|
|
/******************************************************************************
|
|
|
|
* GetMultipleTrusteeA [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
PTRUSTEEA WINAPI
|
|
|
|
GetMultipleTrusteeA(PTRUSTEE_A pTrustee)
|
|
|
|
{
|
2008-09-21 13:55:53 +00:00
|
|
|
return pTrustee->pMultipleTrustee;
|
2004-12-15 12:29:36 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************
|
|
|
|
* GetMultipleTrusteeW [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
PTRUSTEEW WINAPI
|
|
|
|
GetMultipleTrusteeW(PTRUSTEE_W pTrustee)
|
|
|
|
{
|
2008-09-21 13:55:53 +00:00
|
|
|
return pTrustee->pMultipleTrustee;
|
2004-12-15 12:29:36 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************
|
|
|
|
* GetMultipleTrusteeOperationA [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
MULTIPLE_TRUSTEE_OPERATION WINAPI
|
|
|
|
GetMultipleTrusteeOperationA(PTRUSTEE_A pTrustee)
|
|
|
|
{
|
2008-09-21 13:55:53 +00:00
|
|
|
return pTrustee->MultipleTrusteeOperation;
|
2004-12-15 12:29:36 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************
|
|
|
|
* GetMultipleTrusteeOperationW [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
MULTIPLE_TRUSTEE_OPERATION WINAPI
|
|
|
|
GetMultipleTrusteeOperationW(PTRUSTEE_W pTrustee)
|
|
|
|
{
|
2008-09-21 13:55:53 +00:00
|
|
|
return pTrustee->MultipleTrusteeOperation;
|
2004-12-15 12:29:36 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************
|
|
|
|
* GetTrusteeFormW [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
TRUSTEE_FORM WINAPI
|
|
|
|
GetTrusteeFormA(PTRUSTEE_A pTrustee)
|
|
|
|
{
|
2008-09-21 13:55:53 +00:00
|
|
|
return pTrustee->TrusteeForm;
|
2004-12-15 12:29:36 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************
|
|
|
|
* GetTrusteeFormW [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
TRUSTEE_FORM WINAPI
|
|
|
|
GetTrusteeFormW(PTRUSTEE_W pTrustee)
|
|
|
|
{
|
2008-09-21 13:55:53 +00:00
|
|
|
return pTrustee->TrusteeForm;
|
2004-12-15 12:29:36 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************
|
|
|
|
* GetTrusteeNameA [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
LPSTR WINAPI
|
|
|
|
GetTrusteeNameA(PTRUSTEE_A pTrustee)
|
|
|
|
{
|
2006-04-20 04:28:47 +00:00
|
|
|
return pTrustee->ptstrName;
|
2004-12-15 12:29:36 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************
|
|
|
|
* GetTrusteeNameW [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
LPWSTR WINAPI
|
|
|
|
GetTrusteeNameW(PTRUSTEE_W pTrustee)
|
|
|
|
{
|
2006-04-20 04:28:47 +00:00
|
|
|
return pTrustee->ptstrName;
|
2004-12-15 12:29:36 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************
|
|
|
|
* GetTrusteeTypeA [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
TRUSTEE_TYPE WINAPI
|
|
|
|
GetTrusteeTypeA(PTRUSTEE_A pTrustee)
|
|
|
|
{
|
2008-09-21 13:55:53 +00:00
|
|
|
return pTrustee->TrusteeType;
|
2004-12-15 12:29:36 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************
|
|
|
|
* GetTrusteeTypeW [ADVAPI32.@]
|
|
|
|
*/
|
|
|
|
TRUSTEE_TYPE WINAPI
|
|
|
|
GetTrusteeTypeW(PTRUSTEE_W pTrustee)
|
|
|
|
{
|
2008-09-21 13:55:53 +00:00
|
|
|
return pTrustee->TrusteeType;
|
2004-12-15 12:29:36 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
/* EOF */
|