汇编语言社区
汇编语言社区-学技术网

汇编语言社区

帖子 61互动 85关注 88
x86/64汇编语言交流社区
汇编语言社区-学技术网
x86/x64汇编基础10.汇编基础6:使用x32dbg学习FS与线程TEB-学技术网x86/x64汇编基础10.汇编基础6:使用x32dbg学习FS与线程TEB-学技术网x86/x64汇编基础10.汇编基础6:使用x32dbg学习FS与线程TEB-学技术网
1.写⼀段汇编代码,获取进程 ID 2.写⼀段汇编代码,获取线程 ID 3.写⼀段汇编代码,获取 PEB 地址 #include #include #include using namespace std; int main() { int pid, tid, ebpAddr; __asm { mov eax, fs : [0x20] mov ebx, fs : [0x24] mov ecx, fs : [0x30] mov pid, eax mov tid, ebx mov ebpAddr, ecx } cout << "pic is " << pid << endl; cout << "tid is " << tid << endl; cout << "ebp address is " << ebpAddr << endl; _PEB* ptr = reinterpret_cast(ebpAddr); cout << "debugged is " <BeingDebugged << endl; system("pause"); }
评分
1分享
评分
2分享
评分
1分享
评分
1分享
评分
1分享
评分
1分享
评分
3分享
评分
2分享
评分
2分享
评分
7分享