exploiut-db:4 y6 e* H2 p* N+ E
( Q. M0 g+ C# }8 A. z: w0 OFCKEditor ASP Version 2.6.8 File Upload Protection Bypass A1 z% i( L6 F0 X6 n
; s0 A# @ ~2 s& p% P! ?
- Title: FCKEditor 2.6.8 ASP Version File Upload Protection bypass& s1 E9 U. Y+ g8 n( l1 U- ], }
- Credit goes to: Mostafa Azizi, Soroush Dalili
6 Y3 \ Y' u9 @3 V: C5 C- Link:http://sourceforge.net/projects/fckeditor/files/FCKeditor/
! e0 [5 y1 _: A. E6 m# r* S9 a- Description:" G& |3 n& M# c& M9 ^! D
There is no validation on the extensions when FCKEditor 2.6.8 ASP version is! C" ~, e6 Y5 r- U5 l5 C2 H" B3 b1 e
dealing with the duplicate files. As a result, it is possible to bypass
. c% G" C8 u/ M6 B9 b) Q. \2 \the protection and upload a file with any extension.
9 j6 Q- p" `+ g' P- Reference: http://soroush.secproject.com/blog/2012/11/file-in-the-hole/2 V* I, V3 r/ u$ k
- Solution: Please check the provided reference or the vendor website.# S; j2 S+ @' E$ P
- PoC:http://www.youtube.com/v/1VpxlJ5 ... ;rel=0&vq=hd720: Z! |, [0 S- V( v
"( G. c! H8 e* K% U6 t7 O
Note: Quick patch for FCKEditor 2.6.8 File Upload Bypass:
" @: F( E, X9 X4 [+ d5 [9 MIn “config.asp”, wherever you have:
# M2 p" ]2 K$ B ConfigAllowedExtensions.Add “File”,”Extensions Here”% ~9 `4 ]. q! k* Q0 w# ~
Change it to:1 [3 [" F j4 i" F* N
ConfigAllowedExtensions.Add “File”,”^(Extensions Here)$”
5 ^" c. S9 F% l5 H$ r( c/ b8 A0 d, H( T! ]& y* K+ R
* P7 ]( B+ L2 a- D5 ]7 K4 ^4 r0 Z! E8 q$ z# I. _
: J/ O( R0 ?9 m8 c$ r9 ]: }, R0 c, E9 L; I- w" s& k% v
php测试无效" c% ?. E: T( n3 e N4 `
asp/aspx测试成功:
% W6 w' D9 |* M; X4 c来到/FCKeditor/editor/filemanager/connectors/test.html5 c( `1 I$ B( m, w
因为结合了之前二次上传的漏洞,所以先上传任意内容的文件:asd.asp.txt" E& h8 m7 E0 V
_: M8 p" x# C* p& ^burpsuite上传包并修改,repeater
/ W- l; Z2 e, \$ Y+ `名字改为asd.asp%00txt 然后把%00专为URL编码上传后得到asd(1).asp+ \& ]/ y9 J4 I0 X9 V
6 Y* k- |- h; U9 E1 P8 w
如图,webshell为:http://localhost/userfiles/file/asd(1).asp
, J- q0 a. A. Q% i+ e
( t2 u+ z4 N4 \! c) w |