Created
October 6, 2016 15:18
-
-
Save un4ckn0wl3z/8873b90788efce5d1171f5aee9875e04 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(gdb) set disassembly-flavor intel | |
(gdb) disass validate_passwd | |
Dump of assembler code for function validate_passwd: | |
0x0804849e <+0>: push ebp | |
0x0804849f <+1>: mov ebp,esp | |
0x080484a1 <+3>: push edi | |
0x080484a2 <+4>: sub esp,0x34 | |
0x080484a5 <+7>: mov eax,DWORD PTR [ebp+0x8] | |
0x080484a8 <+10>: mov DWORD PTR [ebp-0x1c],0xffffffff | |
0x080484af <+17>: mov edx,eax | |
0x080484b1 <+19>: mov eax,0x0 | |
0x080484b6 <+24>: mov ecx,DWORD PTR [ebp-0x1c] | |
0x080484b9 <+27>: mov edi,edx | |
0x080484bb <+29>: repnz scas al,BYTE PTR es:[edi] | |
0x080484bd <+31>: mov eax,ecx | |
0x080484bf <+33>: not eax | |
0x080484c1 <+35>: sub eax,0x1 | |
0x080484c4 <+38>: mov BYTE PTR [ebp-0x9],al | |
0x080484c7 <+41>: cmp BYTE PTR [ebp-0x9],0x3 | |
0x080484cb <+45>: jbe 0x8048500 <validate_passwd+98> | |
0x080484cd <+47>: cmp BYTE PTR [ebp-0x9],0x8 | |
0x080484d1 <+51>: ja 0x8048500 <validate_passwd+98> | |
0x080484d3 <+53>: mov DWORD PTR [esp],0x8048660 | |
0x080484da <+60>: call 0x80483a0 <puts@plt> | |
0x080484df <+65>: mov eax,ds:0x804a020 | |
0x080484e4 <+70>: mov DWORD PTR [esp],eax | |
0x080484e7 <+73>: call 0x8048380 <fflush@plt> | |
0x080484ec <+78>: mov eax,DWORD PTR [ebp+0x8] | |
0x080484ef <+81>: mov DWORD PTR [esp+0x4],eax | |
0x080484f3 <+85>: lea eax,[ebp-0x14] | |
0x080484f6 <+88>: mov DWORD PTR [esp],eax | |
0x080484f9 <+91>: call 0x8048390 <strcpy@plt> | |
0x080484fe <+96>: jmp 0x8048519 <validate_passwd+123> | |
0x08048500 <+98>: mov DWORD PTR [esp],0x804866f | |
0x08048507 <+105>: call 0x80483a0 <puts@plt> | |
0x0804850c <+110>: mov eax,ds:0x804a020 | |
0x08048511 <+115>: mov DWORD PTR [esp],eax | |
0x08048514 <+118>: call 0x8048380 <fflush@plt> | |
0x08048519 <+123>: lea eax,[ebp-0x14] | |
0x0804851c <+126>: mov DWORD PTR [esp],eax | |
0x0804851f <+129>: call 0x8048494 <store_passwd_indb> | |
0x08048524 <+134>: add esp,0x34 | |
---Type <return> to continue, or q <return> to quit--- | |
0x08048527 <+137>: pop edi | |
0x08048528 <+138>: pop ebp | |
0x08048529 <+139>: ret |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment