chapter1.1

#include "stdafx.h"


int _tmain(int argc, _TCHAR* argv[])
{
 return 0;
}

 debug

od

 

00411370    55              push    ebp                          ; main函数
00411371    8BEC            mov     ebp, esp
00411373    81EC C0000000   sub     esp, 0C0
00411379    53              push    ebx
0041137A    56              push    esi
0041137B    57              push    edi
0041137C    8DBD 40FFFFFF   lea     edi, dword ptr [ebp-C0]
00411382    B9 30000000     mov     ecx, 30
00411387    B8 CCCCCCCC     mov     eax, CCCCCCCC                ; debug状态,填充CC(INT3),防止Over
0041138C    F3:AB           rep     stos dword ptr es:[edi]
0041138E    33C0            xor     eax, eax                     ; 返回值清0
00411390    5F              pop     edi
00411391    5E              pop     esi
00411392    5B              pop     ebx
00411393    8BE5            mov     esp, ebp
00411395    5D              pop     ebp
00411396    C3              retn

 

 

ida

.text:00411370 ; =============== S U B R O U T I N E =======================================
.text:00411370
.text:00411370 ; Attributes: bp-based frame
.text:00411370
.text:00411370 _wmain          proc near               ; CODE XREF: j__wmainj
.text:00411370
.text:00411370 var_overbuffer  = byte ptr -0C0h
.text:00411370
.text:00411370                 push    ebp
.text:00411371                 mov     ebp, esp
.text:00411373                 sub     esp, 0C0h
.text:00411379                 push    ebx
.text:0041137A                 push    esi
.text:0041137B                 push    edi
.text:0041137C                 lea     edi, [ebp+var_overbuffer]
.text:00411382                 mov     ecx, 30h
.text:00411387                 mov     eax, 0CCCCCCCCh
.text:0041138C                 rep stosd
.text:0041138E                 xor     eax, eax
.text:00411390                 pop     edi
.text:00411391                 pop     esi
.text:00411392                 pop     ebx
.text:00411393                 mov     esp, ebp
.text:00411395                 pop     ebp
.text:00411396                 retn
.text:00411396 _wmain          endp
release

od

 

00401000  /$  33C0          xor     eax, eax
00401002  \.  C3            retn

 

 

ida

; int __cdecl main(int argc, const char **argv, const char *envp)
_main proc near
xor     eax, eax
retn
_main endp

posted @ 2010-06-18 15:07  南守拥  阅读(215)  评论(0编辑  收藏  举报