2 minutes
寻找入口点 回归最开始的美好
寻找主函数
入口点(主函数)并不确定 –> 编译器版本
寻找编译器特征 来确定 主函数
VS 2013-2017 特征
2015 Debug x86
- jmp
- mainCRTStartup里面的call
- 第二个call
- movzx test jz mov mov push call add push call add call(main)
- 最后一个call
- jmp
- main
2015 Release x86
- jmp
- call
__p___argv
mov call__p___argc
mov call_get_initial_narrow_environment
push push push call(main) - main
2015 Debug x64
- jmp
- call
- 第二个call
- movzx test jz mov mov call xor call call(main)
- 最后一个call
- jmp
- main
2015 Release x64
- jmp
- call
__p___argv
movrdi, rax call__p___argc
movrbx, rax call mov mov mov call(main) - main
2017 Debug x86
- jmp
- call
- 第二个call
- movzx ecx, al testecx, ecx jz short loc_411E82 mov mov push call add call (main)
- 最后一个call
- jmp
- main
2017 Release x86
- jmp
- call mov call mov call push push push call(main)
- main
2017 Debug x64
- jmp
- call
- 第二个call
- movzx test jz mov mov call call(main)
- 最后一个call
- jmp
- main
2017 Release x64
- jmp
- call
__p___argv
mov call__p___argc
mov call mov mov mov call(main) - main
2019 Debug x86
- jmp
- call
- 第二个call
- movzx test jz mov mov push call add call(main)
- 最后一个call
- jmp
- main
2019 Release x86
- jmp
- call
__p___argv
mov call__p___argc
push push push call(main) - main
2019 Debug x64
- jmp
- call
- 第二个call
- movzx test jz mov mov call call(main)
- 最后一个call
- jmp
- main
2019 Release x64
- jmp
- call
__p___argv
mov call__p___argc
push push push call(main) - main
2022 Debug x86
- jmp
- call
- 第二个call
- movzx test je mov mov push call add call(main)
- 最后一个call
- jmp
- main
2022 Release x86
- call
- 第二个call
- movzx test je mov mov push call add call(main)
- 最后一个call
- main
2022 Debug x64
- jmp
- call
- 第二个call
- movzx test je mov mov call call(main)
- 最后一个call
- jmp
- main
2022 Release x64
- call
__p___argv
mov call__p___argc
mov mov mov call(main) - main
MinGW GCC
x86 Debug
- jmp
- call mov mov mov mov mov mov mov mov mov call(main)
- main
x86 Release
-
jmp
-
call mov mov mov mov mov mov mov mov mov call(main)
-
main
x64 Debug
- 第二个call
- call mov mov mov mov mov mov mov call(main)
- main
x64 Release
- 第二个call
- call mov mov mov mov mov mov mov call(main)
- main
Clang
x86 Debug
- jmp
- call mov call mov call push push push call
- main
x86 Release
- jmp
- call mov call mov call push push push call
- main
x64 Debug
- jmp
- call mov call mov call mov mov mov call
- main
x64 Release
- jmp
- call mov call mov call mov mov mov call
- main
Go Build
-
jmp
-
jmp
-
call mov mov mov mov call call call learax, mainflag
-
dq offset runtime_main
-
lea call mov mov call mov call cmp jnz cmp jnz mov lea callmain
-
main
Read other posts