ntdll: Implement NtQueryInformationToken(TokenElevation).
Signed-off-by: Zebediah Figura <z.figura12@gmail.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
ec9244f056
commit
3c677c3f08
|
@ -8130,7 +8130,7 @@ static void test_elevation(void)
|
|||
ok(type == TokenElevationTypeLimited, "got type %#x\n", type);
|
||||
ret = GetTokenInformation(linked.LinkedToken, TokenElevation, &elevation, sizeof(elevation), &size);
|
||||
ok(ret, "got error %u\n", GetLastError());
|
||||
todo_wine ok(elevation.TokenIsElevated == FALSE, "got elevation %#x\n", elevation.TokenIsElevated);
|
||||
ok(elevation.TokenIsElevated == FALSE, "got elevation %#x\n", elevation.TokenIsElevated);
|
||||
|
||||
/* Asking for the linked token again gives us a different token. */
|
||||
ret = GetTokenInformation(token, TokenLinkedToken, &linked2, sizeof(linked2), &size);
|
||||
|
@ -8141,7 +8141,7 @@ static void test_elevation(void)
|
|||
ok(type == TokenElevationTypeLimited, "got type %#x\n", type);
|
||||
ret = GetTokenInformation(linked2.LinkedToken, TokenElevation, &elevation, sizeof(elevation), &size);
|
||||
ok(ret, "got error %u\n", GetLastError());
|
||||
todo_wine ok(elevation.TokenIsElevated == FALSE, "got elevation %#x\n", elevation.TokenIsElevated);
|
||||
ok(elevation.TokenIsElevated == FALSE, "got elevation %#x\n", elevation.TokenIsElevated);
|
||||
|
||||
check_different_token(linked.LinkedToken, linked2.LinkedToken);
|
||||
|
||||
|
|
|
@ -403,11 +403,15 @@ NTSTATUS WINAPI NtQueryInformationToken( HANDLE token, TOKEN_INFORMATION_CLASS c
|
|||
break;
|
||||
|
||||
case TokenElevation:
|
||||
SERVER_START_REQ( get_token_elevation )
|
||||
{
|
||||
TOKEN_ELEVATION *elevation = info;
|
||||
FIXME("QueryInformationToken( ..., TokenElevation, ...) semi-stub\n");
|
||||
elevation->TokenIsElevated = TRUE;
|
||||
|
||||
req->handle = wine_server_obj_handle( token );
|
||||
status = wine_server_call( req );
|
||||
if (!status) elevation->TokenIsElevated = (reply->elevation == TokenElevationTypeFull);
|
||||
}
|
||||
SERVER_END_REQ;
|
||||
break;
|
||||
|
||||
case TokenSessionId:
|
||||
|
|
Loading…
Reference in New Issue