aboutsummaryrefslogtreecommitdiff
path: root/client/src/util/util.h
diff options
context:
space:
mode:
authorauth12 <[email protected]>2020-07-27 09:46:17 -0700
committerauth12 <[email protected]>2020-07-27 09:46:17 -0700
commita2e89fde1acc5b189c55e0b8b38146194e455cd0 (patch)
tree1f130027975733e0704a583aebb1a1832a22ec11 /client/src/util/util.h
parentCompile fix. (diff)
downloadloader-a2e89fde1acc5b189c55e0b8b38146194e455cd0.tar.xz
loader-a2e89fde1acc5b189c55e0b8b38146194e455cd0.zip
Removed spdlog, using fmt wrapper instead.
More process class changes, support for 32/64bit processes. Injection process improvements. Other small changes.
Diffstat (limited to 'client/src/util/util.h')
-rw-r--r--client/src/util/util.h17
1 files changed, 2 insertions, 15 deletions
diff --git a/client/src/util/util.h b/client/src/util/util.h
index 8734bd9..0a1e17f 100644
--- a/client/src/util/util.h
+++ b/client/src/util/util.h
@@ -1,26 +1,13 @@
#pragma once
#include "native.h"
-#include "../injection/pe.h"
namespace util {
-
- extern std::unordered_map<std::string, pe::virtual_image> loaded_modules;
-
std::string wide_to_multibyte(const std::wstring& str);
std::wstring multibyte_to_wide(const std::string& str);
- native::_PEB* cur_peb();
-
- bool init();
-
- static pe::virtual_image& ntdll() {
- static pe::virtual_image nt{};
- if (!nt) {
- nt = loaded_modules["ntdll.dll"];
- nt.parse_exports();
- }
- return nt;
+ __forceinline native::_PEB* peb() {
+ return reinterpret_cast<native::_PEB*>(__readgsqword(0x60));
}
bool close_handle(HANDLE handle);