#ifndef _WINSTA_H
// rev
NTSYSAPI
BOOLEAN
NTAPI
LogonIdFromWinStationNameW(
_In_opt_ HANDLE ServerHandle,
_In_ PCWSTR WinStationName,
_Out_ PULONG SessionId
);
View code on GitHubThis function is a wrapper over an RPC method documented in the [MS-TSTS] specification.