[DllImport("advapi32.dll", SetLastError=true)]
static extern IntPtr LsaEnumerateAccountRights(
IntPtr PolicyHandle,
IntPtr AccountSid,
string UserRights, //?
ref ulong CountOfRights //?
);
// NTSTATUS LsaEnumerateAccountRights(
// LSA_HANDLE PolicyHandle,
// PSID AccountSid,
// PLSA_UNICODE_STRING* UserRights,
// PULONG CountOfRights
//);
Declare Function LsaEnumerateAccountRights Lib "advapi32.dll" (TODO) As TODO
None.
Just making a start. I'll be back soon when I've researched how to deal with NTSTATUS codes. Got to go dig in some header files.
Right - got it - NTSTATUS is a long, so I guess an IntPtr - I guess the place to document this is LsaNtStatusToWinError
Meanwhile - LSA_HANDLE is a PVOID - that makes sense for an opaque handle, so I guess I'll use an IntPtr again. Not completely confident about this though.
Still a work in progress!!
Please add some!
Please add some!
Do you know one? Please contribute it!