Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <Windows.h>
- #include <string>
- #include <fstream>
- using namespace std;
- DWORD GetOpCodeNameAddress = 0x0191D0A0;
- string GetOpCodeName(DWORD Opcode)
- {
- unsigned int pointer = 0;
- _asm
- {
- push Opcode
- call GetOpCodeNameAddress
- add esp, 4
- mov [pointer], eax
- }
- return string((LPCSTR)pointer);
- }
- DWORD WINAPI Thread(LPVOID nothing)
- {
- ofstream fileOut;
- fileOut.open("opcodes.txt", ios::out);
- string name = "";
- for (int i = 0; i < 0x10000; i++)
- {
- name = GetOpCodeName(i);
- if (name != "")
- {
- fileOut << name << " = " << i << "," << endl;
- }
- }
- fileOut.close();
- return 1;
- }
- BOOL WINAPI DllMain(HINSTANCE Hinst, DWORD Reason, LPVOID Somethingelse)
- {
- switch (Reason)
- {
- case DLL_PROCESS_ATTACH:
- MessageBoxA(0, "Injected", "Desu", 0);
- CreateThread(0, 0, Thread, 0, 0, 0);
- case DLL_PROCESS_DETACH:
- MessageBoxA(0, "Finished.", "Desu", 0);
- }
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment