mirror of
https://github.com/reactos/reactos.git
synced 2025-06-12 01:38:29 +00:00
[NTOS:PS] Fix stack memory disclosure in PsGetContextThread #3024
Fix stack memory disclosure in PsGetContextThread.
This commit is contained in:
parent
49be08bc69
commit
bc584bdf99
1 changed files with 2 additions and 1 deletions
|
@ -112,7 +112,7 @@ PsGetContextThread(IN PETHREAD Thread,
|
||||||
/* Enter SEH */
|
/* Enter SEH */
|
||||||
_SEH2_TRY
|
_SEH2_TRY
|
||||||
{
|
{
|
||||||
/* Set default ength */
|
/* Set default length */
|
||||||
Size = sizeof(CONTEXT);
|
Size = sizeof(CONTEXT);
|
||||||
|
|
||||||
/* Read the flags */
|
/* Read the flags */
|
||||||
|
@ -146,6 +146,7 @@ PsGetContextThread(IN PETHREAD Thread,
|
||||||
KeInitializeEvent(&GetSetContext.Event, NotificationEvent, FALSE);
|
KeInitializeEvent(&GetSetContext.Event, NotificationEvent, FALSE);
|
||||||
|
|
||||||
/* Set the flags and previous mode */
|
/* Set the flags and previous mode */
|
||||||
|
RtlZeroMemory(&GetSetContext.Context, Size);
|
||||||
GetSetContext.Context.ContextFlags = Flags;
|
GetSetContext.Context.ContextFlags = Flags;
|
||||||
GetSetContext.Mode = PreviousMode;
|
GetSetContext.Mode = PreviousMode;
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue