找回密码
 立即注册
欢迎中测联盟老会员回家,1997年注册的域名
查看: 2251|回复: 0
打印 上一主题 下一主题

最新FCKEditor ASP上传绕过漏洞

[复制链接]
跳转到指定楼层
楼主
发表于 2012-12-10 10:18:50 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
exploiut-db:
- t  v) l3 t: s8 R% ~( c3 C' l. w. o) _0 N. \
FCKEditor ASP Version 2.6.8 File Upload Protection Bypass
2 ^3 H1 \/ _9 [6 s+ S* G: C: }- O2 S, {( |4 k& Q5 N4 t8 c1 u* a
- Title: FCKEditor 2.6.8 ASP Version File Upload Protection bypass
6 i" F* O6 L$ O6 f, }' ?- Credit goes to: Mostafa Azizi, Soroush Dalili' E& d, E4 R# S+ n
- Link:http://sourceforge.net/projects/fckeditor/files/FCKeditor/& x) ]# r7 u( [7 K4 t# h. m$ l
- Description:
8 @3 z! s* {2 k0 O$ x4 j9 V" TThere is no validation on the extensions when FCKEditor 2.6.8 ASP version is+ [  E! P. ?2 S8 X  n1 l
dealing with the duplicate files. As a result, it is possible to bypass4 |; u% D5 N0 B! @, h
the protection and upload a file with any extension.5 ~( s; B- ]! {0 W. N
- Reference: http://soroush.secproject.com/blog/2012/11/file-in-the-hole/% \% \# D+ i. \: x2 c8 B/ J
- Solution: Please check the provided reference or the vendor website.  X* E- `+ }& b8 X5 K4 e7 j9 R
- PoC:http://www.youtube.com/v/1VpxlJ5 ... ;rel=0&vq=hd7201 }0 Q( X2 I+ F9 `9 |$ l
"+ E+ o! J% k! i! N/ i2 t
Note: Quick patch for FCKEditor 2.6.8 File Upload Bypass:
; [0 [( n  ~3 G  n6 RIn “config.asp”, wherever you have:( g% v8 O: d9 }) X8 }+ u. S0 x) |
      ConfigAllowedExtensions.Add    “File”,”Extensions Here”9 t+ T3 j  v, S
Change it to:
* B8 h7 ~5 A: t# l      ConfigAllowedExtensions.Add    “File”,”^(Extensions Here)$”  }; _0 b1 N$ _; P

9 j3 `0 A9 i+ ~, A 7 U- S& K, Z) e% C
1 b0 c2 o: r) t* i

3 N+ T  d5 O& W& {4 Y9 M2 m
/ G  M# M' \! }$ Aphp测试无效
# i, i2 P  w/ g: j% \asp/aspx测试成功:* E1 X* @6 N2 \, y! ^# @4 x, l
来到/FCKeditor/editor/filemanager/connectors/test.html
. q8 _& m' n; J$ W因为结合了之前二次上传的漏洞,所以先上传任意内容的文件:asd.asp.txt, V: A' t$ y( ]2 S/ \( e
: ?( e6 n/ w, k3 X2 x$ t+ Q
burpsuite上传包并修改,repeater5 ^! L6 X4 d2 F* |
名字改为asd.asp%00txt    然后把%00专为URL编码上传后得到asd(1).asp2 r/ w% `8 L6 a: N+ {% V0 y

! L9 G$ l/ |# Z8 q. a3 {如图,webshell为:http://localhost/userfiles/file/asd(1).asp
5 m7 o, ], Q0 `* B( \, x7 m* M4 P. g( C/ q* c7 n
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

快速回复 返回顶部 返回列表