SecurityReason.com - Our Reason is

Security

Register | Forget Password | Login
SecurityReason
WLB
Services
RSS
Corporate
Note

If you have found a vulnerability, please send to our SecurityAlert Database :
secalert()securityreason()com

Also if you have new ( 0-day ) exploit, please send to our ExploitAlert Archive :
exploit()securityreason()com

Home arrow SecurityAlert Database

Arrow  Topic :

SQL Injection by using Cookie Poisoning for Website Baker Version 2.6.5 and before


Arrow  SecurityAlert : 2185
Arrow  CVE : CVE-2007-0527
Arrow  SecurityRisk : Medium  Security Risk Medium  (About)
Arrow  Remote Exploit : Yes
Arrow  Local Exploit : No
Arrow  Exploit Available : No
Arrow  Credit : Rolf Huisman
Arrow  Published : 29.01.2007

Arrow  Affected Software : Website Baker Version 2.6.5



Arrow  Advisory Content :  

Website Baker Version 2.6.5 and before contains a SQL injection.
This can be exploited by using Cookie Poisoning

Manufacturer was notified, but want to ignore the request pending release
version 3.0

Poison the cookie for the login page with the REMEMBER_KEY variable with a
standard sql injection ('; <Insert Your SQL Statment here> --)

Failing function is in class.login.php
// Function to check if a user has been remembered
function is_remembered() {
if(isset($_COOKIE['REMEMBER_KEY']) AND $_COOKIE['REMEMBER_KEY']
!= '') {
// Check if the remember key is correct
$database = new database();
$check_query = $database->query("SELECT user_id FROM
".$this->USERS_TABLE." WHERE remember_key = '".$_COOKIE['REMEMBER_KEY']."'
LIMIT 1");

This function is called by the login screen, hence the vulnerability.
When changing the user table... Free admin login :P

HotFix:
Change $database->query("SELECT user_id FROM ".$this->USERS_TABLE." WHERE
remember_key = '".$_COOKIE['REMEMBER_KEY']."' LIMIT 1");
into
$database->query("SELECT user_id FROM ".$this->USERS_TABLE." WHERE
remember_key = '".addslashes($_COOKIE['REMEMBER_KEY'])."' LIMIT 1");

$query_details = $database->query("SELECT * FROM ".$this->USERS_TABLE."
WHERE user_id = '".substr($_COOKIE['REMEMBER_KEY'], 0, 11)."' LIMIT 1");
into
$query_details = $database->query("SELECT * FROM ".$this->USERS_TABLE."
WHERE user_id = '".substr(addslashes($_COOKIE['REMEMBER_KEY']), 0, 11)."'
LIMIT 1");

With Regards

Rolf Huisman





Arrow  Feedback :

If you have additional information or notice any errors regarding this security advisory, please use contact form or email us at info()securityreason()com.
Alert

libc:fts_*() Multiple Denial of Service

Security Risk Medium- 2009-10-02

The fts functions are provided for traversing UNIX file hierarchies...

Apache RSS Apache Alert

» Apache 1.3.41 mod_proxy
   Integer overflow (code
   execution)

» Apache Tomcat 6.0.20 and
   5.5.28 unexpected file
   deletion in work
   directory

» Apache Tomcat 6.0.20 and
   5.5.28 insecure partial
   deploy after failed
   undeploy

» Apache Tomcat 6.0.20 and
   5.5.28 unexpected file
   deletion and/or
   alteration

PHP RSS PHP Alert

» PHP 5.2.12/5.3.1
   session.save_path
   safe_mode and
   open_basedir bypass

» PHP 5.2.12/5.3.1 Multiple
   Vulnerabilities

» PHP 5.2.11 libgd multiple
   vulnerabilities

» PHP 5.2.11 tempnam()
   safe_mode bypass

Copyright © SecurityReason.com. All Rights Reserved.