Reactos
1//
2// peb_access.cpp
3//
4// Copyright (c) Microsoft Corporation. All rights reserved.
5//
6// Wrapper functions to access fields in the PEB.
7//
8
9// Using internal headers for definitions. Only call publicly available functions.
10#include <nt.h>
11#include <ntrtl.h>
12#include <nturtl.h>
13
14extern "C" bool __cdecl __acrt_app_verifier_enabled()
15{
16 return (NtCurrentTeb()->ProcessEnvironmentBlock->NtGlobalFlag & FLG_APPLICATION_VERIFIER) != 0;
17}
18
19extern "C" bool __cdecl __acrt_is_secure_process()
20{
21 return (NtCurrentTeb()->ProcessEnvironmentBlock->ProcessParameters->Flags & RTL_USER_PROC_SECURE_PROCESS) != 0;
22}