exploiut-db:; t; @# L0 [1 v
3 r8 g' |+ g! d) ?' I- l- A
FCKEditor ASP Version 2.6.8 File Upload Protection Bypass( d6 Q! T( P. G x' K
6 h2 n( Q7 h& H+ f4 a5 l( t- Title: FCKEditor 2.6.8 ASP Version File Upload Protection bypass- w; ~ t7 K8 W
- Credit goes to: Mostafa Azizi, Soroush Dalili1 o0 Q( L; c7 y" i, c/ v
- Link:http://sourceforge.net/projects/fckeditor/files/FCKeditor/
8 {7 ?+ n. O! B3 x- Description:
$ Q; E% V1 ~, D- }There is no validation on the extensions when FCKEditor 2.6.8 ASP version is, D+ P8 f5 L$ R: G! f
dealing with the duplicate files. As a result, it is possible to bypass
+ B/ \+ E! u T6 @9 Z4 @& Nthe protection and upload a file with any extension.
! j" j8 ^: e- {" {/ T k% i9 D- Reference: http://soroush.secproject.com/blog/2012/11/file-in-the-hole/
1 p6 @/ T1 }0 X( ?. B6 ]! q) L- Solution: Please check the provided reference or the vendor website.
" X9 L/ q+ |. n; a! p2 \# D- PoC:http://www.youtube.com/v/1VpxlJ5 ... ;rel=0&vq=hd720" S3 Z' E) r. Q# f
"4 @# g3 W# H6 Q( Y6 E! @
Note: Quick patch for FCKEditor 2.6.8 File Upload Bypass:
% M, X2 s: V t; h0 |0 @! _2 @In “config.asp”, wherever you have:# E1 O! l' L; \" ?2 d
ConfigAllowedExtensions.Add “File”,”Extensions Here”
' F" h1 v+ K5 m: ~. a$ F8 GChange it to:. `4 B$ [, r4 m
ConfigAllowedExtensions.Add “File”,”^(Extensions Here)$”1 l. q& N* `' G/ t% }' g
! M/ d$ m* r( h" }' p
5 u& l" h; k O |' B1 n' L4 ^- L
6 o" @6 U" N9 B" q' {- g0 I/ C 6 G) u" |7 y" I9 D, L! s
5 Y3 y! }: O; e& \2 f T0 Y5 Yphp测试无效
# B2 U7 F; s9 _/ @8 d5 L, |asp/aspx测试成功:8 ^; ?$ n6 x% X; W4 [; p4 |0 C# r
来到/FCKeditor/editor/filemanager/connectors/test.html. C" t0 _. q- G0 {
因为结合了之前二次上传的漏洞,所以先上传任意内容的文件:asd.asp.txt
/ w- Z* v: r- W0 r2 v- s- n
1 c. h: H6 M; |5 P# |1 Z! `burpsuite上传包并修改,repeater4 A/ c" [* }, C* l
名字改为asd.asp%00txt 然后把%00专为URL编码上传后得到asd(1).asp5 k( O& [' @- p
- |& S$ w0 n- c% p, W$ H1 j% z7 ]) e
如图,webshell为:http://localhost/userfiles/file/asd(1).asp
/ @. Y, L% M& R3 X' S: k$ x* b2 t; w8 y* `* Y
|