+ // Dynamically link OpenProcessToken, LookupPrivilegeValue and AdjustTokenPrivileges
+ HMODULE k32 = GetModuleHandle("Advapi32.dll");
+ auto fun6 = (fun6_t)(void(*)())GetProcAddress(k32, "OpenProcessToken");
+ if (!fun6)
+ return nullptr;
+ auto fun7 = (fun7_t)(void(*)())GetProcAddress(k32, "LookupPrivilegeValueA");
+ if (!fun7)
+ return nullptr;
+ auto fun8 = (fun8_t)(void(*)())GetProcAddress(k32, "AdjustTokenPrivileges");
+ if (!fun8)
+ return nullptr;
+
+