中国网络渗透测试联盟

标题: 最新FCKEditor ASP上传绕过漏洞 [打印本页]

作者: admin    时间: 2012-12-10 10:18
标题: 最新FCKEditor ASP上传绕过漏洞
exploiut-db:# G! O5 q: A! Z. O2 u) d

/ f8 c+ z. t  @2 O6 n' HFCKEditor ASP Version 2.6.8 File Upload Protection Bypass0 C& j- ~! m9 Y# B! @
  o. F  E9 c; a3 F. r
- Title: FCKEditor 2.6.8 ASP Version File Upload Protection bypass( {$ O# {: [8 F6 U" H- ~
- Credit goes to: Mostafa Azizi, Soroush Dalili
2 y. k$ ^3 J" `* _7 t  |6 E0 M- Link:http://sourceforge.net/projects/fckeditor/files/FCKeditor/3 ?& \1 f3 D* K8 r* i
- Description:, s6 A* m6 \& L3 i
There is no validation on the extensions when FCKEditor 2.6.8 ASP version is4 P0 u+ R( D& m4 E
dealing with the duplicate files. As a result, it is possible to bypass4 |8 j4 @: K6 u7 M# L' ?9 r
the protection and upload a file with any extension.1 h- l0 p& k6 Q0 M4 g9 H
- Reference: http://soroush.secproject.com/blog/2012/11/file-in-the-hole/- A* u6 o% ]' n. e3 S  J2 L
- Solution: Please check the provided reference or the vendor website.+ l: m9 b7 w. V  S; a+ g+ I; S
- PoC:http://www.youtube.com/v/1VpxlJ5 ... ;rel=0&vq=hd7205 ~6 h3 H$ c) D1 o. P7 F
"
# ]+ i  y  R/ _' k% x/ gNote: Quick patch for FCKEditor 2.6.8 File Upload Bypass:- H+ m7 d1 X" [% E9 i4 a  v6 Y
In “config.asp”, wherever you have:
7 R" q* g6 \4 a  b# }/ w      ConfigAllowedExtensions.Add    “File”,”Extensions Here”8 v8 I5 B6 p* Q3 J# f$ F9 Z
Change it to:
8 a3 `' j& C3 M      ConfigAllowedExtensions.Add    “File”,”^(Extensions Here)$”
1 L( J% z" x- S- |* P! o6 l; U' M# {- W$ K- S. W7 _
# \4 Z; o$ d" ^, z4 D
& @! a# J3 L, Z( z. e; _

# ]4 F8 L$ ?0 x" b$ F8 X* w. J! p- L: D$ E$ p" L% j
php测试无效
/ s& G* l% p; Q8 t* ~  v' W: m; Hasp/aspx测试成功:  I, \! j/ @1 v
来到/FCKeditor/editor/filemanager/connectors/test.html
; s6 G, e8 W, Y# X; `: ^7 q2 D因为结合了之前二次上传的漏洞,所以先上传任意内容的文件:asd.asp.txt6 ~. ~/ v/ m& z" n& @) h: N

: F8 g6 G$ E: ~* @( r) t1 C6 hburpsuite上传包并修改,repeater! X3 n7 j/ K! p8 Q& f
名字改为asd.asp%00txt    然后把%00专为URL编码上传后得到asd(1).asp
% ~5 d& ~7 C, I+ d: I; `
) G! z; G7 M; l& w如图,webshell为:http://localhost/userfiles/file/asd(1).asp
5 ~4 p; R; w0 ?* x% R& z+ H
2 O' M" [' H' u# b8 G




欢迎光临 中国网络渗透测试联盟 (https://www.cobjon.com/) Powered by Discuz! X3.2