|
25 | 25 | * |
26 | 26 | * |
27 | 27 | * ============================== SECTIONS ================================== |
28 | | - * - enums for publicly accessible techniques => line 551 |
29 | | - * - struct for internal cpu operations => line 744 |
30 | | - * - struct for internal memoization => line 1198 |
31 | | - * - struct for internal utility functions => line 1323 |
32 | | - * - struct for internal core components => line 10057 |
33 | | - * - start of VM detection technique list => line 2522 |
34 | | - * - start of public VM detection functions => line 10721 |
35 | | - * - start of externally defined variables => line 11644 |
| 28 | + * - enums for publicly accessible techniques => line 553 |
| 29 | + * - struct for internal cpu operations => line 746 |
| 30 | + * - struct for internal memoization => line 1200 |
| 31 | + * - struct for internal utility functions => line 1325 |
| 32 | + * - struct for internal core components => line 10055 |
| 33 | + * - start of VM detection technique list => line 2521 |
| 34 | + * - start of public VM detection functions => line 10719 |
| 35 | + * - start of externally defined variables => line 11642 |
36 | 36 | * |
37 | 37 | * |
38 | 38 | * ============================== EXAMPLE =================================== |
|
184 | 184 | #pragma once |
185 | 185 |
|
186 | 186 | #if defined(_WIN32) || defined(_WIN64) |
| 187 | +#define WIN32_LEAN_AND_MEAN |
187 | 188 | #define WINDOWS 1 |
188 | 189 | #define LINUX 0 |
189 | 190 | #define APPLE 0 |
@@ -1931,9 +1932,6 @@ struct VM { |
1931 | 1932 | * These child partitions have limited privileges and access to hypervisor resources, |
1932 | 1933 | * which is reflected in the maximum input value for hypervisor CPUID information as 11. |
1933 | 1934 | * Essentially, it indicates that the hypervisor is managing the VM and that the VM is not running directly on hardware but rather in a virtualized environment. |
1934 | | - * |
1935 | | - * On the other hand, in bare-metal systems running Hyper-V, the EAX value is 12. |
1936 | | - * This higher value corresponds to the root partition, which has more privileges and control over virtualization resources compared to child partitions. |
1937 | 1935 | */ |
1938 | 1936 | auto eax = []() -> u32 { |
1939 | 1937 | char out[sizeof(int32_t) * 4 + 1] = { 0 }; |
@@ -2626,7 +2624,6 @@ struct VM { |
2626 | 2624 | #if (!x86) |
2627 | 2625 | return false; |
2628 | 2626 | #else |
2629 | | - |
2630 | 2627 | if (util::hyper_x() == HYPERV_ARTIFACT_VM) { |
2631 | 2628 | return false; |
2632 | 2629 | } |
|
0 commit comments