-
Notifications
You must be signed in to change notification settings - Fork 65
Expand file tree
/
Copy pathPPLHelp.h
More file actions
30 lines (25 loc) · 699 Bytes
/
PPLHelp.h
File metadata and controls
30 lines (25 loc) · 699 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#pragma once
#include <windows.h>
#include <iostream>
#include <string>
#include <vector>
#include <cstdlib>
#pragma comment(lib, "advapi32.lib")
class PPLProcessCreator
{
private:
HANDLE m_hProcess;
HANDLE m_hThread;
public:
PPLProcessCreator() : m_hProcess(nullptr), m_hThread(nullptr) {}
~PPLProcessCreator()
{
if (m_hProcess) CloseHandle(m_hProcess);
if (m_hThread) CloseHandle(m_hThread);
}
DWORD GetPPLProtectionLevel(DWORD processId);
std::wstring GetPPLProtectionLevelName(DWORD protectionLevel);
bool CreatePPLProcess(DWORD protectionLevel, std::wstring& commandLine);
HANDLE GetProcessHandle();
HANDLE GetThreadHandle();
};