-
Notifications
You must be signed in to change notification settings - Fork 1
/
main.cpp
57 lines (46 loc) · 1.96 KB
/
main.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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
#include <cstddef>
#include <functional>
#include <iostream>
#include <string>
#include <synchapi.h>
#include <vector>
#include <windows.h>
#include "logger.hpp"
#include "detector.hpp"
int main() {
std::cout << " ______ _ _ _ _ " << std::endl <<
" \\~~~~/ __ _(_)_ __ ___ __| | ___| |_ ___ ___| |_ ___ _ __ " << std::endl <<
" \\ / \\ \\ /\\ / / | '_ \\ / _ \\/ _` |/ _ \\ __/ _ \\/ __| __/ _ \\| '__|" << std::endl <<
" [] \\ V V /| | | | | __/ (_| | __/ || __/ (__| || (_) | | " << std::endl <<
" [] \\_/\\_/ |_|_| |_|\\___|\\__,_|\\___|\\__\\___|\\___|\\__\\___/|_| " << std::endl <<
" ---- " << std::endl <<
" WINEDETECTOR V0.3.1 \n" << std::endl;
Logger logger;
Detector detector;
std::vector<std::function<Detect()>> functptr = {
[&detector]() { return detector.drivesTest(); },
[&detector]() { return detector.registryTest(); },
[&detector]() { return detector.servicesTest(); },
[&detector]() { return detector.processTest(); },
[&detector]() { return detector.filesTest(); },
// [&detector]() { return detector.muldivTest(); },
[&detector]() { return detector.dllExportTest(); },
[&detector]() { return detector.legacyApiTest(); },
// [&detector]() { return detector.unimplementedTest(); }
};
for (size_t i = 0; i < functptr.size(); i++) {
Detect detect = (functptr[i])();
logger.log("[~] Tested " + (detect.name) +". Result: ");
if (detect.detected) {
logger.error("DETECTED\n");
}
else {
logger.success("PASSED\n");
}
Sleep(500);
}
logger.log("\n");
logger.warning("[+] Done! Test points: "+ std::to_string(detector.getScore()) + "/" + std::to_string(detector.getTotalScore()) + "\n");
Sleep(5000);
return 0;
}