Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ================================================================================
- gdb$ disas main
- ================================================================================
- Dump of assembler code for function main:
- 0x08049021 <main+0>: push %ebp
- 0x08049022 <main+1>: mov %esp,%ebp
- 0x08049024 <main+3>: and $0xfffffff0,%esp
- 0x08049027 <main+6>: sub $0x20,%esp
- 0x0804902a <main+9>: movl $0x0,0x1c(%esp) ; (0x1c(%esp)) = 0
- ; while( 0x1c(%esp) <= 19 ){
- 0x08049032 <main+17>: jmp 0x8049055 <main+52>
- 0x08049034 <main+19>: mov 0x1c(%esp),%eax
- 0x08049038 <main+23>: add $0xd10,%eax ; %eax = (0x1c(%esp)) + 3344
- 0x0804903d <main+28>: mov %eax,(%esp)
- 0x08049040 <main+31>: call 0x8048c11 <setup>
- 0x08049045 <main+36>: mov %eax,0x18(%esp) ; 0x18(%esp) = setup(%eax)
- 0x08049049 <main+40>: cmpl $0x0,0x18(%esp) ; if( 0x18(%esp) > 0 )
- 0x0804904e <main+45>: jg 0x804905e <main+61> ; break;
- 0x08049050 <main+47>: addl $0x1,0x1c(%esp) ; (0x1c(%esp)) += 1
- 0x08049055 <main+52>: cmpl $0x13,0x1c(%esp)
- 0x0804905a <main+57>: jle 0x8049034 <main+19>
- 0x0804905c <main+59>: jmp 0x804905f <main+62>
- ;}
- 0x0804905e <main+61>: nop
- ;if( 0x18(%esp) > 0 ){
- 0x0804905f <main+62>: cmpl $0x0,0x18(%esp)
- 0x08049064 <main+67>: jle 0x8049094 <main+115>
- 0x08049066 <main+69>: mov 0x1c(%esp),%eax
- 0x0804906a <main+73>: lea 0xd10(%eax),%edx ; %edx = (0x1c(%esp)) + 3344
- 0x08049070 <main+79>: mov $0x8049227,%eax ; %eax = "port: %d\n"
- 0x08049075 <main+84>: mov %edx,0x4(%esp) ;
- 0x08049079 <main+88>: mov %eax,(%esp) ;
- 0x0804907c <main+91>: call 0x804885c <printf@plt> ; printf("port: %d\n", (0x1c(%esp)) + 3344);
- 0x08049081 <main+96>: mov 0x18(%esp),%eax
- 0x08049085 <main+100>: mov %eax,(%esp)
- 0x08049088 <main+103>: call 0x8048d59 <loop> ; loop( 0x18(%esp) )
- 0x0804908d <main+108>: mov $0x0,%eax
- 0x08049092 <main+113>: leave
- 0x08049093 <main+114>: ret ; return 0
- ; }else{
- 0x08049094 <main+115>: movl $0x8049231,(%esp)
- 0x0804909b <main+122>: call 0x80488ac <puts@plt> ; puts("Fail");
- 0x080490a0 <main+127>: movl $0x1,(%esp)
- 0x080490a7 <main+134>: call 0x80488fc <exit@plt> ; exit(1);
- ; }
- End of assembler dump.
- ================================================================================
- gdb$ disas setup
- ================================================================================
- Dump of assembler code for function setup:
- 0x08048c11 <setup+0>: push %ebp
- 0x08048c12 <setup+1>: mov %esp,%ebp
- 0x08048c14 <setup+3>: sub $0x38,%esp
- 0x08048c17 <setup+6>: movl $0x1,0x4(%esp)
- 0x08048c1f <setup+14>: movl $0x11,(%esp)
- 0x08048c26 <setup+21>: call 0x804873c <signal@plt> ; signal(0x11, 1)
- 0x08048c2b <setup+26>: movw $0x2,-0x1c(%ebp) ; -0x1c(%ebp) = 2
- 0x08048c31 <setup+32>: movl $0x0,(%esp)
- 0x08048c38 <setup+39>: call 0x80488cc <htonl@plt> ; -0x18(%ebp) = htonl(0)
- 0x08048c3d <setup+44>: mov %eax,-0x18(%ebp)
- 0x08048c40 <setup+47>: mov 0x8(%ebp),%eax
- 0x08048c43 <setup+50>: movzwl %ax,%eax
- 0x08048c46 <setup+53>: mov %eax,(%esp)
- 0x08048c49 <setup+56>: call 0x80487bc <htons@plt>
- 0x08048c4e <setup+61>: mov %ax,-0x1a(%ebp) ; -0x1a(%ebp) = htons((short)arg)
- 0x08048c52 <setup+65>: movl $0x0,0x8(%esp)
- 0x08048c5a <setup+73>: movl $0x1,0x4(%esp)
- 0x08048c62 <setup+81>: movl $0x2,(%esp)
- 0x08048c69 <setup+88>: call 0x804881c <socket@plt> ; -0xc(%ebp) = socket(2,1,0)
- 0x08048c6e <setup+93>: mov %eax,-0xc(%ebp)
- ; if( -0xc(%ebp) == -1 ){
- 0x08048c71 <setup+96>: cmpl $0xffffffff,-0xc(%ebp)
- 0x08048c75 <setup+100>: jne 0x8048c8a <setup+121>
- 0x08048c77 <setup+102>: movl $0x80491ce,(%esp)
- 0x08048c7e <setup+109>: call 0x80487dc <perror@plt> ; perror("socket()")
- 0x08048c83 <setup+114>: mov $0xffffffff,%eax
- 0x08048c88 <setup+119>: jmp 0x8048ce9 <setup+216> ; return -1;
- ; }
- 0x08048c8a <setup+121>: lea -0x1c(%ebp),%eax
- 0x08048c8d <setup+124>: movl $0x10,0x8(%esp)
- 0x08048c95 <setup+132>: mov %eax,0x4(%esp)
- 0x08048c99 <setup+136>: mov -0xc(%ebp),%eax
- 0x08048c9c <setup+139>: mov %eax,(%esp)
- 0x08048c9f <setup+142>: call 0x804886c <bind@plt> ; %eax = bind(-0xc(%ebp), &(0x1c(%ebp)), 16);
- ; if( %eax != 0 ){
- 0x08048ca4 <setup+147>: test %eax,%eax
- 0x08048ca6 <setup+149>: je 0x8048cbb <setup+170>
- 0x08048ca8 <setup+151>: movl $0x80491d7,(%esp)
- 0x08048caf <setup+158>: call 0x80487dc <perror@plt> ; perror("bind()")
- 0x08048cb4 <setup+163>: mov $0xffffffff,%eax ; return -1
- 0x08048cb9 <setup+168>: jmp 0x8048ce9 <setup+216>
- ; }
- 0x08048cbb <setup+170>: movl $0xc8,0x4(%esp)
- 0x08048cc3 <setup+178>: mov -0xc(%ebp),%eax
- 0x08048cc6 <setup+181>: mov %eax,(%esp)
- 0x08048cc9 <setup+184>: call 0x804876c <listen@plt>
- 0x08048cce <setup+189>: cmp $0xffffffff,%eax
- 0x08048cd1 <setup+192>: jne 0x8048ce6 <setup+213>
- 0x08048cd3 <setup+194>: movl $0x80491de,(%esp) ;"listen()"
- 0x08048cda <setup+201>: call 0x80487dc <perror@plt>
- 0x08048cdf <setup+206>: mov $0xffffffff,%eax
- 0x08048ce4 <setup+211>: jmp 0x8048ce9 <setup+216>
- 0x08048ce6 <setup+213>: mov -0xc(%ebp),%eax
- 0x08048ce9 <setup+216>: leave
- 0x08048cea <setup+217>: ret
- End of assembler dump.
- ================================================================================
- gdb$ disas loop
- ================================================================================
- Dump of assembler code for function loop:
- 0x08048d59 <loop+0>: push %ebp
- 0x08048d5a <loop+1>: mov %esp,%ebp
- 0x08048d5c <loop+3>: sub $0x38,%esp
- 0x08048d5f <loop+6>: movl $0x10,-0x24(%ebp)
- 0x08048d66 <loop+13>: lea -0x20(%ebp),%eax
- 0x08048d69 <loop+16>: lea -0x24(%ebp),%edx
- 0x08048d6c <loop+19>: mov %edx,0x8(%esp)
- 0x08048d70 <loop+23>: mov %eax,0x4(%esp)
- 0x08048d74 <loop+27>: mov 0x8(%ebp),%eax
- 0x08048d77 <loop+30>: mov %eax,(%esp)
- 0x08048d7a <loop+33>: call 0x804880c <accept@plt>
- 0x08048d7f <loop+38>: mov %eax,-0x10(%ebp)
- 0x08048d82 <loop+41>: cmpl $0xffffffff,-0x10(%ebp)
- 0x08048d86 <loop+45>: jne 0x8048d96 <loop+61>
- 0x08048d88 <loop+47>: movl $0x80491ee,(%esp)
- 0x08048d8f <loop+54>: call 0x80487dc <perror@plt>
- 0x08048d94 <loop+59>: jmp 0x8048de3 <loop+138>
- 0x08048d96 <loop+61>: call 0x80488bc <fork@plt>
- 0x08048d9b <loop+66>: mov %eax,-0xc(%ebp)
- 0x08048d9e <loop+69>: cmpl $0xffffffff,-0xc(%ebp)
- 0x08048da2 <loop+73>: jne 0x8048db2 <loop+89>
- 0x08048da4 <loop+75>: movl $0x80491e7,(%esp)
- 0x08048dab <loop+82>: call 0x80487dc <perror@plt>
- 0x08048db0 <loop+87>: jmp 0x8048de3 <loop+138>
- 0x08048db2 <loop+89>: cmpl $0x0,-0xc(%ebp)
- 0x08048db6 <loop+93>: jne 0x8048dd6 <loop+125>
- 0x08048db8 <loop+95>: mov 0x8(%ebp),%eax
- 0x08048dbb <loop+98>: mov %eax,0x4(%esp)
- 0x08048dbf <loop+102>: mov -0x10(%ebp),%eax
- 0x08048dc2 <loop+105>: mov %eax,(%esp)
- 0x08048dc5 <loop+108>: call 0x8048ec1 <handle>
- 0x08048dca <loop+113>: movl $0x0,(%esp)
- 0x08048dd1 <loop+120>: call 0x80488fc <exit@plt>
- 0x08048dd6 <loop+125>: mov -0x10(%ebp),%eax
- 0x08048dd9 <loop+128>: mov %eax,(%esp)
- 0x08048ddc <loop+131>: call 0x804887c <close@plt>
- 0x08048de1 <loop+136>: jmp 0x8048d66 <loop+13>
- 0x08048de3 <loop+138>: jmp 0x8048d66 <loop+13>
- End of assembler dump.
- ================================================================================
- gdb$ disas handle
- ================================================================================
- 0x08048ec1 <handle+0>: push %ebp
- 0x08048ec2 <handle+1>: mov %esp,%ebp
- 0x08048ec4 <handle+3>: sub $0x828,%esp
- 0x08048eca <handle+9>: movl $0x258,(%esp)
- 0x08048ed1 <handle+16>: call 0x804884c <alarm@plt> ; alarm( 600 )
- 0x08048ed6 <handle+21>: movl $0x400,0x8(%esp)
- 0x08048ede <handle+29>: movl $0x0,0x4(%esp)
- 0x08048ee6 <handle+37>: lea -0x40c(%ebp),%eax
- 0x08048eec <handle+43>: mov %eax,(%esp)
- 0x08048eef <handle+46>: call 0x804877c <memset@plt> ; memset( &(-0x40c(%ebp)), 0, 1024 )
- 0x08048ef4 <handle+51>: movl $0x400,0x8(%esp)
- 0x08048efc <handle+59>: movl $0x0,0x4(%esp)
- 0x08048f04 <handle+67>: lea -0x80c(%ebp),%eax
- 0x08048f0a <handle+73>: mov %eax,(%esp)
- 0x08048f0d <handle+76>: call 0x804877c <memset@plt> ; memset( &(-0x80c(%ebp)), 0, 1024 )
- 0x08048f12 <handle+81>: movl $0x0,0xc(%esp)
- 0x08048f1a <handle+89>: movl $0xa,0x8(%esp)
- 0x08048f22 <handle+97>: movl $0x8049211,0x4(%esp) ;"username:"
- 0x08048f2a <handle+105>: mov 0x8(%ebp),%eax
- 0x08048f2d <handle+108>: mov %eax,(%esp)
- 0x08048f30 <handle+111>: call 0x804889c <send@plt> ; send( 0x8(%ebp), "username:", 0xa, 0 )
- 0x08048f35 <handle+116>: movl $0x0,0xc(%esp)
- 0x08048f3d <handle+124>: movl $0x3ff,0x8(%esp)
- 0x08048f45 <handle+132>: lea -0x40c(%ebp),%eax
- 0x08048f4b <handle+138>: mov %eax,0x4(%esp)
- 0x08048f4f <handle+142>: mov 0x8(%ebp),%eax
- 0x08048f52 <handle+145>: mov %eax,(%esp)
- 0x08048f55 <handle+148>: call 0x804875c <recv@plt> ; -0xc(%ebp) = recv( 0x8(%ebp), &(-0x40c(%ebp)), 1023, 0 )
- 0x08048f5a <handle+153>: mov %eax,-0xc(%ebp)
- ; if( -0xc(%ebp) > 0 ){
- 0x08048f5d <handle+156>: cmpl $0x0,-0xc(%ebp)
- 0x08048f61 <handle+160>: jle 0x8048f71 <handle+176>
- 0x08048f63 <handle+162>: mov -0xc(%ebp),%eax
- 0x08048f66 <handle+165>: sub $0x1,%eax ; -0xc(%ebp) - 1
- 0x08048f69 <handle+168>: movb $0x0,-0x40c(%ebp,%eax,1) ; I think this is null terminating the buffer it doesn't receive anything
- ; }
- 0x08048f71 <handle+176>: movl $0x0,0xc(%esp)
- 0x08048f79 <handle+184>: movl $0xa,0x8(%esp)
- 0x08048f81 <handle+192>: movl $0x804921c,0x4(%esp); "password: "
- 0x08048f89 <handle+200>: mov 0x8(%ebp),%eax
- 0x08048f8c <handle+203>: mov %eax,(%esp)
- 0x08048f8f <handle+206>: call 0x804889c <send@plt> ; send( 0x8(%ebp), "password: ", 10, 0 )
- 0x08048f94 <handle+211>: movl $0x0,0xc(%esp)
- 0x08048f9c <handle+219>: movl $0x3ff,0x8(%esp)
- 0x08048fa4 <handle+227>: lea -0x80c(%ebp),%eax
- 0x08048faa <handle+233>: mov %eax,0x4(%esp)
- 0x08048fae <handle+237>: mov 0x8(%ebp),%eax
- 0x08048fb1 <handle+240>: mov %eax,(%esp)
- 0x08048fb4 <handle+243>: call 0x804875c <recv@plt> ; -0xc(%ebp) = recv( 0x8(%ebp), &(-0x80c(%ebp)), 1023, 0 )
- 0x08048fb9 <handle+248>: mov %eax,-0xc(%ebp)
- 0x08048fbc <handle+251>: cmpl $0x0,-0xc(%ebp)
- 0x08048fc0 <handle+255>: jle 0x8048fd0 <handle+271>
- 0x08048fc2 <handle+257>: mov -0xc(%ebp),%eax
- 0x08048fc5 <handle+260>: sub $0x1,%eax
- 0x08048fc8 <handle+263>: movb $0x0,-0x80c(%ebp,%eax,1)
- 0x08048fd0 <handle+271>: lea -0x80c(%ebp),%eax
- 0x08048fd6 <handle+277>: mov %eax,0x4(%esp)
- 0x08048fda <handle+281>: lea -0x40c(%ebp),%eax
- 0x08048fe0 <handle+287>: mov %eax,(%esp)
- 0x08048fe3 <handle+290>: call 0x80489c4 <auth> ; -0xc(%ebp) = auth( -0x40c(%ebp), -0x80c(%ebp) )
- 0x08048fe8 <handle+295>: mov %eax,-0xc(%ebp)
- 0x08048feb <handle+298>: cmpl $0x0,-0xc(%ebp)
- 0x08048fef <handle+302>: jne 0x8048ffd <handle+316>
- 0x08048ff1 <handle+304>: movl $0x1,(%esp)
- 0x08048ff8 <handle+311>: call 0x80488fc <exit@plt>
- 0x08048ffd <handle+316>: lea -0x40c(%ebp),%eax
- 0x08049003 <handle+322>: mov %eax,(%esp)
- 0x08049006 <handle+325>: call 0x8048ad9 <findshell> ; %eax = findshell( &(-0x40c(%ebp)) )
- 0x0804900b <handle+330>: mov 0x8(%ebp),%edx
- 0x0804900e <handle+333>: mov %edx,0x4(%esp)
- 0x08049012 <handle+337>: mov %eax,(%esp)
- 0x08049015 <handle+340>: call 0x8048bab <makeshell> ; makeshell( %eax, 0x8(%ebp) )
- 0x0804901a <handle+345>: mov $0x0,%eax
- 0x0804901f <handle+350>: leave
- 0x08049020 <handle+351>: ret
- End of assembler dump.
- ================================================================================
- gdb$ disas auth
- ================================================================================
- Dump of assembler code for function auth:
- 0x080489c4 <auth+0>: push %ebp
- 0x080489c5 <auth+1>: mov %esp,%ebp
- 0x080489c7 <auth+3>: sub $0x28,%esp
- 0x080489ca <auth+6>: movl $0x0,-0xc(%ebp) ; -0xc(%ebp) = 0
- ; while( -0xc(%ebp) <= 1 ) {
- 0x080489d1 <auth+13>: jmp 0x8048ac8 <auth+260>
- 0x080489d6 <auth+18>: mov -0xc(%ebp),%eax
- 0x080489d9 <auth+21>: imul $0xc08,%eax,%eax
- 0x080489df <auth+27>: add $0x804a3e0,%eax ;"level3"
- 0x080489e4 <auth+32>: mov %eax,0x4(%esp)
- 0x080489e8 <auth+36>: mov 0x8(%ebp),%eax
- 0x080489eb <auth+39>: mov %eax,(%esp)
- 0x080489ee <auth+42>: call 0x80488ec <strcmp@plt> ; %eax = strcmp( username, "level3"+((-0xc(%ebp))*3080) );
- ; if( %eax != 0 ){
- 0x080489f3 <auth+47>: test %eax,%eax
- 0x080489f5 <auth+49>: jne 0x8048ac4 <auth+256>
- 0x080489fb <auth+55>: mov -0xc(%ebp),%eax
- 0x080489fe <auth+58>: imul $0xc08,%eax,%eax
- 0x08048a04 <auth+64>: add $0x400,%eax
- 0x08048a09 <auth+69>: add $0x804a3e0,%eax ;"level3"
- 0x08048a0e <auth+74>: mov %eax,0x4(%esp)
- 0x08048a12 <auth+78>: mov 0xc(%ebp),%eax
- 0x08048a15 <auth+81>: mov %eax,(%esp)
- 0x08048a18 <auth+84>: call 0x80488ec <strcmp@plt> ; %eax = strcmp( 0xc(%ebp), "level3"+1024+(3080*(-0xc(%ebp))) )
- ; if( %eax != 0 ){
- 0x08048a1d <auth+89>: test %eax,%eax
- 0x08048a1f <auth+91>: jne 0x8048ac4 <auth+256>
- 0x08048a25 <auth+97>: mov -0xc(%ebp),%eax
- 0x08048a28 <auth+100>: imul $0xc08,%eax,%eax
- 0x08048a2e <auth+106>: mov 0x804abe4(%eax),%eax
- 0x08048a34 <auth+112>: mov %eax,0x4(%esp)
- 0x08048a38 <auth+116>: mov 0x8(%ebp),%eax
- 0x08048a3b <auth+119>: mov %eax,(%esp)
- 0x08048a3e <auth+122>: call 0x804888c <initgroups@plt>
- 0x08048a43 <auth+127>: mov -0xc(%ebp),%eax
- 0x08048a46 <auth+130>: imul $0xc08,%eax,%eax
- 0x08048a4c <auth+136>: mov 0x804abe4(%eax),%ecx
- 0x08048a52 <auth+142>: mov -0xc(%ebp),%eax
- 0x08048a55 <auth+145>: imul $0xc08,%eax,%eax
- 0x08048a5b <auth+151>: mov 0x804abe4(%eax),%edx
- 0x08048a61 <auth+157>: mov -0xc(%ebp),%eax
- 0x08048a64 <auth+160>: imul $0xc08,%eax,%eax
- 0x08048a6a <auth+166>: mov 0x804abe4(%eax),%eax
- 0x08048a70 <auth+172>: mov %ecx,0x8(%esp)
- 0x08048a74 <auth+176>: mov %edx,0x4(%esp)
- 0x08048a78 <auth+180>: mov %eax,(%esp)
- 0x08048a7b <auth+183>: call 0x80487fc <setresgid@plt>
- 0x08048a80 <auth+188>: mov -0xc(%ebp),%eax
- 0x08048a83 <auth+191>: imul $0xc08,%eax,%eax
- 0x08048a89 <auth+197>: mov 0x804abe0(%eax),%ecx
- 0x08048a8f <auth+203>: mov -0xc(%ebp),%eax
- 0x08048a92 <auth+206>: imul $0xc08,%eax,%eax
- 0x08048a98 <auth+212>: mov 0x804abe0(%eax),%edx
- 0x08048a9e <auth+218>: mov -0xc(%ebp),%eax
- 0x08048aa1 <auth+221>: imul $0xc08,%eax,%eax
- 0x08048aa7 <auth+227>: mov 0x804abe0(%eax),%eax
- 0x08048aad <auth+233>: mov %ecx,0x8(%esp)
- 0x08048ab1 <auth+237>: mov %edx,0x4(%esp)
- 0x08048ab5 <auth+241>: mov %eax,(%esp)
- 0x08048ab8 <auth+244>: call 0x80487ec <setresuid@plt>
- 0x08048abd <auth+249>: mov $0x1,%eax
- 0x08048ac2 <auth+254>: jmp 0x8048ad7 <auth+275> ; break
- ; }
- ; }
- 0x08048ac4 <auth+256>: addl $0x1,-0xc(%ebp) ; -0xc(%ebp) += 1
- 0x08048ac8 <auth+260>: cmpl $0x1,-0xc(%ebp)
- 0x08048acc <auth+264>: jle 0x80489d6 <auth+18>
- ; }
- 0x08048ad2 <auth+270>: mov $0x0,%eax
- 0x08048ad7 <auth+275>: leave
- 0x08048ad8 <auth+276>: ret ; return 0
- End of assembler dump.
- ================================================================================
- gdb$ disas findshell
- ================================================================================
- 0x08048ad9 <findshell+0>: push %ebp
- 0x08048ada <findshell+1>: mov %esp,%ebp
- 0x08048adc <findshell+3>: sub $0x28,%esp
- 0x08048adf <findshell+6>: movl $0x0,-0xc(%ebp)
- 0x08048ae6 <findshell+13>: jmp 0x8048b25 <findshell+76>
- 0x08048ae8 <findshell+15>: mov -0xc(%ebp),%eax
- 0x08048aeb <findshell+18>: imul $0xc08,%eax,%eax
- 0x08048af1 <findshell+24>: add $0x804a3e0,%eax ;"level3"
- 0x08048af6 <findshell+29>: mov %eax,0x4(%esp)
- 0x08048afa <findshell+33>: mov 0x8(%ebp),%eax
- 0x08048afd <findshell+36>: mov %eax,(%esp)
- 0x08048b00 <findshell+39>: call 0x80488ec <strcmp@plt>
- 0x08048b05 <findshell+44>: test %eax,%eax
- 0x08048b07 <findshell+46>: jne 0x8048b21 <findshell+72>
- 0x08048b09 <findshell+48>: mov -0xc(%ebp),%eax
- 0x08048b0c <findshell+51>: imul $0xc08,%eax,%eax
- 0x08048b12 <findshell+57>: add $0x800,%eax
- 0x08048b17 <findshell+62>: add $0x804a3e0,%eax ;"level3"
- 0x08048b1c <findshell+67>: add $0x8,%eax
- 0x08048b1f <findshell+70>: jmp 0x8048b30 <findshell+87>
- 0x08048b21 <findshell+72>: addl $0x1,-0xc(%ebp)
- 0x08048b25 <findshell+76>: cmpl $0x1,-0xc(%ebp)
- 0x08048b29 <findshell+80>: jle 0x8048ae8 <findshell+15>
- 0x08048b2b <findshell+82>: mov $0x8049170,%eax ;"/usr/sbin/nologin"
- 0x08048b30 <findshell+87>: leave
- 0x08048b31 <findshell+88>: ret
- End of assembler dump.
- ================================================================================
- gdb$ disas makeshell
- ================================================================================
- Dump of assembler code for function makeshell:
- 0x08048bab <makeshell+0>: push %ebp
- 0x08048bac <makeshell+1>: mov %esp,%ebp
- 0x08048bae <makeshell+3>: sub $0x18,%esp
- 0x08048bb1 <makeshell+6>: movl $0x0,0x4(%esp)
- 0x08048bb9 <makeshell+14>: mov 0xc(%ebp),%eax
- 0x08048bbc <makeshell+17>: mov %eax,(%esp)
- 0x08048bbf <makeshell+20>: call 0x804882c <dup2@plt>
- 0x08048bc4 <makeshell+25>: movl $0x1,0x4(%esp)
- 0x08048bcc <makeshell+33>: mov 0xc(%ebp),%eax
- 0x08048bcf <makeshell+36>: mov %eax,(%esp)
- 0x08048bd2 <makeshell+39>: call 0x804882c <dup2@plt>
- 0x08048bd7 <makeshell+44>: movl $0x2,0x4(%esp)
- 0x08048bdf <makeshell+52>: mov 0xc(%ebp),%eax
- 0x08048be2 <makeshell+55>: mov %eax,(%esp)
- 0x08048be5 <makeshell+58>: call 0x804882c <dup2@plt>
- 0x08048bea <makeshell+63>: movl $0x0,0x8(%esp)
- 0x08048bf2 <makeshell+71>: movl $0x80491bf,0x4(%esp) ;"logind-session"
- 0x08048bfa <makeshell+79>: mov 0x8(%ebp),%eax
- 0x08048bfd <makeshell+82>: mov %eax,(%esp)
- 0x08048c00 <makeshell+85>: call 0x80487ac <execl@plt>
- 0x08048c05 <makeshell+90>: movl $0x2,(%esp)
- 0x08048c0c <makeshell+97>: call 0x80488fc <exit@plt>
- End of assembler dump.
Add Comment
Please, Sign In to add comment