Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (gdb) disass main
- Dump of assembler code for function main:
- 0x08048557 <+0>: push ebp
- 0x08048558 <+1>: mov ebp,esp
- 0x0804855a <+3>: and esp,0xfffffff0
- 0x0804855d <+6>: sub esp,0x10
- 0x08048560 <+9>: cmp DWORD PTR [ebp+0x8],0x2
- 0x08048564 <+13>: je 0x8048582 <main+43>
- 0x08048566 <+15>: mov eax,DWORD PTR [ebp+0xc]
- 0x08048569 <+18>: mov eax,DWORD PTR [eax]
- 0x0804856b <+20>: mov DWORD PTR [esp+0x4],eax
- 0x0804856f <+24>: mov DWORD PTR [esp],0x8048680
- 0x08048576 <+31>: call 0x80483a0 <printf@plt>
- 0x0804857b <+36>: mov eax,0x1
- 0x08048580 <+41>: jmp 0x80485ed <main+150>
- 0x08048582 <+43>: mov eax,DWORD PTR [ebp+0xc]
- 0x08048585 <+46>: add eax,0x4
- 0x08048588 <+49>: mov eax,DWORD PTR [eax]
- 0x0804858a <+51>: mov DWORD PTR [esp],eax
- 0x0804858d <+54>: call 0x80484ec <check>
- 0x08048592 <+59>: cmp eax,0x1
- 0x08048595 <+62>: jne 0x80485c9 <main+114>
- 0x08048597 <+64>: mov DWORD PTR [esp],0x8048696
- 0x0804859e <+71>: call 0x80483c0 <puts@plt>
- ---Type <return> to continue, or q <return> to quit---
- 0x080485a3 <+76>: mov DWORD PTR [esp],0x80486b4
- 0x080485aa <+83>: call 0x80483c0 <puts@plt>
- 0x080485af <+88>: mov DWORD PTR [esp],0x80486db
- 0x080485b6 <+95>: call 0x80483c0 <puts@plt>
- 0x080485bb <+100>: mov DWORD PTR [esp],0x80486f8
- 0x080485c2 <+107>: call 0x80483d0 <system@plt>
- 0x080485c7 <+112>: jmp 0x80485ed <main+150>
- 0x080485c9 <+114>: mov DWORD PTR [esp],0x8048696
- 0x080485d0 <+121>: call 0x80483c0 <puts@plt>
- 0x080485d5 <+126>: mov DWORD PTR [esp],0x804871a
- 0x080485dc <+133>: call 0x80483c0 <puts@plt>
- 0x080485e1 <+138>: mov DWORD PTR [esp],0x80486db
- 0x080485e8 <+145>: call 0x80483c0 <puts@plt>
- 0x080485ed <+150>: leave
- 0x080485ee <+151>: ret
- End of assembler dump.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement