MCPcopy Create free account
hub / github.com/bailey27/cppcryptfs / GetUserNameFromDokanFileInfo

Function GetUserNameFromDokanFileInfo

cppcryptfs/dokan/cryptdokan.cpp:138–153  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

136
137
138static bool GetUserNameFromDokanFileInfo(PDOKAN_FILE_INFO DokanFileInfo, wstring& user, wstring& domain)
139{
140 HANDLE handle;
141
142 handle = DokanOpenRequestorToken(DokanFileInfo);
143 if (handle == INVALID_HANDLE_VALUE) {
144 DbgPrint(L" DokanOpenRequestorToken failed\n");
145 return false;
146 }
147
148 const bool bRet = GetUserNameFromToken(handle, user, domain);
149
150 CloseHandle(handle);
151
152 return bRet;
153}
154
155static bool GetSessionIdFromDokanFileInfo(PDOKAN_FILE_INFO DokanFileInfo, DWORD& sessionid)
156{

Callers

nothing calls this directly

Calls 2

DbgPrintFunction · 0.85
GetUserNameFromTokenFunction · 0.85

Tested by

no test coverage detected