Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
3c677c3f
Commit
3c677c3f
authored
Feb 16, 2021
by
Zebediah Figura
Committed by
Alexandre Julliard
Feb 17, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Implement NtQueryInformationToken(TokenElevation).
Signed-off-by:
Zebediah Figura
<
z.figura12@gmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
ec9244f0
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
4 deletions
+8
-4
security.c
dlls/advapi32/tests/security.c
+2
-2
security.c
dlls/ntdll/unix/security.c
+6
-2
No files found.
dlls/advapi32/tests/security.c
View file @
3c677c3f
...
...
@@ -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
);
...
...
dlls/ntdll/unix/security.c
View file @
3c677c3f
...
...
@@ -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
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment