OllyDbg 无法调试 Visual Studio exe

OllyDbg can't debug visual studio exe

本文关键字:Studio exe Visual 调试 OllyDbg      更新时间:2023-10-16

我刚刚用这个简单的代码创建了一个新的vc++ exe:

#include<stdio.h>
#include<string.h>
#include<windows.h>
int ExceptionHandler(void);
int main(int argc,char *argv[]){
char temp[512];
printf("Application launched");
try 
{
  throw "error";
} 
catch (... )
{
    ExceptionHandler();
}
return 0;
}
int ExceptionHandler(void)
{
    printf("Exception");
    return 0;
}

该应用程序非常简单,并创建了一个依赖于kernel32.dll和MSVCR100D.dll的exe文件。

当我尝试将其导入并调试到OllyDbg(我只是想在堆栈窗口中看到SEH链)时,它说"模块'testseh'在代码外部具有入口点(如PE头中指定的)。也许这个文件是自提取或自修改的。当设置断点时请记住它!"并且没有执行代码,它直接跳转到ntdll.dll崩溃部分(实际上exe正在崩溃,但我不能一步一步地执行printf指令)

为什么会有这种行为?exe不依赖于CLI也CLR,我错过了什么?

编译器从olly中获取异常为critical(错误设置)