-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathchecker.cpp
38 lines (35 loc) · 877 Bytes
/
checker.cpp
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
30
31
32
33
34
35
36
37
38
#include <windows.h>
#include <stdio.h>
#include <string>
#include <vector>
std::vector<std::string> targets = {
"GDIPLUS.DLL", // OLDA, NEWA
"GDI32.DLL", // OLDA, NEWA
"icudt.dll", // OLDA
"WINMM.dll", // OLDA
"KERNEL32.dll", // OLDA, OLDW, NEWA, NEWW
"USER32.dll", // OLDA, OLDW, NEWA
"GDI32.dll", // OLDA, NEWA
"ADVAPI32.dll", // OLDA, OLDW, NEWW
"COMCTL32.dll", // OLDA, NEWA
"dbghelp.dll", // OLDW
"mscoree.dll", // OLDW, NEWS
"combase.dll", // OLDW
"api-ms-win-core-synch-l1-2-0.dll", // NEWW
"api-ms-win-core-registry-l1-1-0.dll" // NEWW
};
int main(int argc, char **argv)
{
if(argc > 1) {
for(auto &v : targets) {
CopyFile("probe.dll", v.c_str(), FALSE);
HMODULE hModule = LoadLibrary(argv[1]);
Sleep(1000);
if(hModule) {
FreeLibrary(hModule);
}
DeleteFile(v.c_str());
}
}
return 0;
}