what you don't know can hurt you

Small-CMS 1.0 SQL Injection

Small-CMS 1.0 SQL Injection
Posted Oct 2, 2012
Authored by Phizo

Small-CMS version 1.0 suffers from authentication bypass and remote SQL injection vulnerabilities.

tags | advisory, remote, vulnerability, sql injection
MD5 | d1a85f056e0747d1ea2a34677a66f35e

Small-CMS 1.0 SQL Injection

Change Mirror Download

[+] Exploit title: Small-CMS 1.0 - SQL injection/Authentication Bypass
[+] Date: 2/10/2012
[+] Author: Phizo
[+] Vendor: http://www.small-cms.com/
[+] Version: 1.0
[+] Category: webapps
[+] Google dork: intitle:"Find it yourself."
[+] Tested on: Windows 7 | Firefox 15.0.1



=================================
default.class.php ~ lines 220-230
=================================

function checkCredentials($username, $password){
$obscure = $this->obscure($password);
$query = "SELECT * FROM ".$this->prefix_db."users WHERE user_name = '$username' AND user_pass = '$obscure' AND user_active = '1' LIMIT 1;";
$result = mysql_query($query) or die(mysql_error());
$row = mysql_fetch_array($result);
if ($row) {
return true;
} else {
return false;
}
}


=================================
default.class.php ~ lines 260-275
=================================

function setSession($username,$password,$cookie){

$query = "SELECT id FROM ".$this->prefix_db."users WHERE user_name = '$username' AND user_pass = '$password' AND user_active = '1' LIMIT 1;";
$result = mysql_query($query) or die(mysql_error());
$row = mysql_fetch_array($result);


$values = array($username,$this->obscure($password),$row['id']);
$session = implode(",",$values);
if($cookie=='on'){
//cookies
setcookie("$this->session_name", $session, time()+60*60*24*100,'/');
} else {
$_SESSION["$this->session_name"] = $session;
}
}


=======================
login.php ~ lines 27-33
=======================

if ($login->checkCredentials($_POST['username'], $_POST['password'])){
$login->setSession($_POST['username'],$_POST['password'],$_POST['cookie']);
$login->redirect('index.php?page=admincp');
} else {
$error = '';
}
}
Login or Register to add favorites

File Archive:

December 2021

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Dec 1st
    18 Files
  • 2
    Dec 2nd
    11 Files
  • 3
    Dec 3rd
    23 Files
  • 4
    Dec 4th
    0 Files
  • 5
    Dec 5th
    0 Files
  • 6
    Dec 6th
    13 Files
  • 7
    Dec 7th
    12 Files
  • 8
    Dec 8th
    19 Files
  • 9
    Dec 9th
    0 Files
  • 10
    Dec 10th
    0 Files
  • 11
    Dec 11th
    0 Files
  • 12
    Dec 12th
    0 Files
  • 13
    Dec 13th
    0 Files
  • 14
    Dec 14th
    0 Files
  • 15
    Dec 15th
    0 Files
  • 16
    Dec 16th
    0 Files
  • 17
    Dec 17th
    0 Files
  • 18
    Dec 18th
    0 Files
  • 19
    Dec 19th
    0 Files
  • 20
    Dec 20th
    0 Files
  • 21
    Dec 21st
    0 Files
  • 22
    Dec 22nd
    0 Files
  • 23
    Dec 23rd
    0 Files
  • 24
    Dec 24th
    0 Files
  • 25
    Dec 25th
    0 Files
  • 26
    Dec 26th
    0 Files
  • 27
    Dec 27th
    0 Files
  • 28
    Dec 28th
    0 Files
  • 29
    Dec 29th
    0 Files
  • 30
    Dec 30th
    0 Files
  • 31
    Dec 31st
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2020 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close