Desktop Functions: Smart Device Functions:
|
Search Results for "LUID" in [All]Structures1: BSMINFO
public LUID LUID;
private static extern uint LsaGetLogonSessionData(IntPtr luid, out IntPtr ppLogonSessionData); 4: LUID
public struct LUID_AND_ATTRIBUTES {
public LUID Luid;
Structure LUID_AND_ATTRIBUTES
Public Luid As LUID
public struct LUID_AND_ATTRIBUTES {
public LUID Luid;
Structure LUID_AND_ATTRIBUTES
Public Luid As LUID
LUID_AND_ATTRIBUTES[] Privilege; LUID_AND_ATTRIBUTES - http://www.pinvoke.net/default.aspx/Structures/LUID_AND_ATTRIBUTES.html
public LUID LoginID;
public LUID_AND_ATTRIBUTES [] Privileges;
public LUID Luid;
Public TheLuid As LUID Do NOT define LUID as UInt64! Use the structure LUID consisted of two UInt32 because of memory alignment.
tp.TheLuid = luid_Restore Constants9: PROPERTYKEY
public static PropertyKey PKEY_PNPX_NetworkInterfaceLuid = new PropertyKey(0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003007); // VT_UI8 10: WINERROR
/// Too many local user identifiers (LUIDs) were requested at one time.
public const int ERROR_TOO_MANY_LUIDS_REQUESTED = 1333;
/// No more local user identifiers (LUIDs) are available.
public const int ERROR_LUIDS_EXHAUSTED = 1334; ntdll11: PROCESSINFOCLASS
ProcessLUIDDeviceMapsEnabled, // q: ULONG secur32
IntPtr PAuthenticationID,//_LUID AuthenticationID,//pvLogonID, //PLUID
IntPtr PAuthenticationID,//_LUID AuthenticationID,//pvLogonID, //PLUID private static extern uint LsaGetLogonSessionData(IntPtr luid, out IntPtr ppLogonSessionData); private struct LUID
public LUID LoginID;
IntPtr luidPtr = IntPtr.Zero;
LsaEnumerateLogonSessions(out count, out luidPtr); //gets an array of pointers to LUIDs
IntPtr iter = luidPtr; //set the pointer to the start of the array
iter = (IntPtr)((int)iter + Marshal.SizeOf(typeof(LUID))); //move the pointer forward
LsaFreeReturnBuffer(luidPtr); //free the array of LUIDs 15: LsaLogonUser
public static extern bool AllocateLocallyUniqueId([Out] out UInt64 Luid); advapi32
ref TokPriv1Luid newst, int len, IntPtr prev, IntPtr relen);
ref long pluid);
internal struct TokPriv1Luid
public long Luid;
TokPriv1Luid tp;
tp.Luid = 0;
retVal = LookupPrivilegeValue(null, SE_TIME_ZONE_NAMETEXT, ref tp.Luid);
var locallyUniqueIdentifier = new NativeMethods.LUID();
TOKEN_PRIVILEGES.Luid = locallyUniqueIdentifier;
internal static extern bool LookupPrivilegeValue(string lpsystemname, string lpname, [MarshalAs(UnmanagedType.Struct)] ref LUID lpLuid);
internal struct LUID
internal LUID Luid;
Private Structure LUID
Private Structure LUID_AND_ATTRIBUTES
Public Luid As LUID
Public Privileges() As LUID_AND_ATTRIBUTES
ByRef lpLuid As LUID _
'Get the LUID that corresponds to the Shutdown privilege, if it exists.
Dim luid_Shutdown As LUID
If Not LookupPrivilegeValue(Nothing, SE_SHUTDOWN_NAME, luid_Shutdown) Then
'Set up a LUID_AND_ATTRIBUTES structure containing the Shutdown privilege, marked as enabled.
Dim luaAttr As New LUID_AND_ATTRIBUTES
luaAttr.Luid = luid_Shutdown
newState.Privileges = New LUID_AND_ATTRIBUTES() {luaAttr}
IntPtr lpLuid,
LUID luid = new LUID();
luid.LowPart = 30;
luid.HighPart = 0;
int luidNameLen = 0;
IntPtr ptrLuid = Marshal.AllocHGlobal(Marshal.SizeOf(luid));
Marshal.StructureToPtr(luidAttr.Luid, ptrLuid, true);
LookupPrivilegeName(null, ptrLuid, null, ref luidNameLen); // call once to get the name len
sb.EnsureCapacity(luidNameLen + 1);
if (LookupPrivilegeName(null, ptrLuid, sb, ref luidNameLen)) // call again to get the name
Trace.WriteLine(string.Format("{0} ({1})", luid.LowPart, sb.ToString()));
Marshal.FreeHGlobal(ptrLuid);
out LUID lpLuid);
lpName As String, ByRef lpLuid As LUID) As Boolean Int64 (or long in C#) could be used instead of LUID.
public long Luid;
if (!LookupPrivilegeValue(null, SE_SHUTDOWN_NAME, out tkp.Privileges[0].Luid)) Enums19: NtStatus
TooManyLuidsRequested = 0xc0000074,
LuidsExhausted = 0xc0000075, rasapi32
public Guid luid; iphlpapi
public UInt64 Luid; |