Lines Matching refs:tokenHandle
38 BOOL getUser(HANDLE tokenHandle, LPTSTR *userName,
40 BOOL getPrimaryGroup(HANDLE tokenHandle, LPTSTR *primaryGroup);
41 BOOL getGroups(HANDLE tokenHandle, PDWORD numGroups, LPTSTR **groups);
64 HANDLE tokenHandle = INVALID_HANDLE_VALUE;
89 if (getToken(&tokenHandle) == FALSE) {
97 (tokenHandle, &userName, &domainName, &userSid, &domainSid) == FALSE) {
104 if (getPrimaryGroup(tokenHandle, &primaryGroup) == FALSE) {
111 if (getGroups(tokenHandle, &numGroups, &groups) == FALSE) {
265 CloseHandle(tokenHandle);
275 BOOL getToken(PHANDLE tokenHandle) {
281 tokenHandle) == 0) {
290 tokenHandle) == 0) {
307 BOOL getUser(HANDLE tokenHandle, LPTSTR *userName,
321 GetTokenInformation(tokenHandle,
328 if (GetTokenInformation(tokenHandle,
441 BOOL getPrimaryGroup(HANDLE tokenHandle, LPTSTR *primaryGroup) {
450 GetTokenInformation(tokenHandle,
458 if (GetTokenInformation(tokenHandle,
494 BOOL getGroups(HANDLE tokenHandle, PDWORD numGroups, LPTSTR **groups) {
504 GetTokenInformation(tokenHandle,
511 if (GetTokenInformation(tokenHandle,
732 HANDLE tokenHandle = INVALID_HANDLE_VALUE;
744 if (getToken(&tokenHandle) == FALSE) {
750 (tokenHandle, &userName, &domainName, &userSid, &domainSid) == FALSE) {
755 if (getPrimaryGroup(tokenHandle, &primaryGroup) == FALSE) {
760 if (getGroups(tokenHandle, &numGroups, &groups) == FALSE) {
801 CloseHandle(tokenHandle);