Dump of assembler code for function ckpass:
0x0804851e <ckpass+0>: push %ebp
0x0804851f <ckpass+1>: mov %esp,%ebp
0x08048521 <ckpass+3>: sub $0x38,%esp
0x08048524 <ckpass+6>: movl $0x10,0x8(%esp)
0x0804852c <ckpass+14>: movl $0x0,0x4(%esp)
0x08048534 <ckpass+22>: lea 0xffffffe8(%ebp),%eax
0x08048537 <ckpass+25>: mov %eax,(%esp)
0x0804853a <ckpass+28>: call 0x80483dc <_init+136>
0x0804853f <ckpass+33>: lea 0xffffffe8(%ebp),%eax
0x08048542 <ckpass+36>: mov %eax,(%esp)
0x08048545 <ckpass+39>: call 0x804839c <_init+72>
*0x0804854a <ckpass+44>: lea 0xffffffe8(%ebp),%eax*
0x0804854d <ckpass+47>: mov %eax,0x4(%esp)
0x08048551 <ckpass+51>: lea 0xffffffd8(%ebp),%eax
0x08048554 <ckpass+54>: mov %eax,(%esp)
0x08048557 <ckpass+57>: call 0x8048571 <hashpass>
0x0804855c <ckpass+62>: lea 0xffffffd8(%ebp),%eax
0x0804855f <ckpass+65>: movl $0x80486e8,0x4(%esp)
0x08048567 <ckpass+73>: mov %eax,(%esp)
0x0804856a <ckpass+76>: call 0x804838c <_init+56>
0x0804856f <ckpass+81>: leave
0x08048570 <ckpass+82>: ret
这是
的反汇编int ckpass()
{
char a[____];
char b[____];
memset(_________, _____, _____);
gets(________);
hashpass(b, a);
return strcmp(________, good_hash);
}
lea 0xffffffe8(%ebp),%eax
究竟是什么意思?
我认为lea s(%ebp),%eax等于eax = epb + s
我在谷歌搜索,它说它意味着缓冲。
但是我在这个例子中有缓冲区a和缓冲区b,我怎么能区分它们呢?
答案 0 :(得分:2)
这意味着eax:= ebp - 16.反汇编程序无法区分有符号和无符号常量。该命令将堆栈中某个变量的地址加载到eax中。