Post: SQLi Vuln Scanner
11-20-2011, 06:28 PM #1
Luulz
Bounty hunter
(adsbygoogle = window.adsbygoogle || []).push({}); Hello.

Im new to python and just made my first script, and i thought i might aswell share it.

Its a script that scanns a website for vulns(for noobs) who dont know how to do it manually.

(Requires: Python 2.0 or newer, and a brain)

Usage: scannr.py <eg. https://example.com/news.php?id=> REMEMBER(Do not add ' after the url, the script does it.

Script:
    
#norwack's private vuln scannr
#made for learning purposes

import os
import urllib2
import sys

def usage():
print "Usage: scannr.py <https://website.com/news.php?id=123>"
argc = len(sys.argv)
if argc < 1:
usage()
else:
link = sys.argv[1] + "'"
for site in urllib2.urlopen(link):
if 'error in your SQL' in site or 'mysql_fetch_' in site:
print "\nMight be vulnerable: ", link


Peace, out.
(adsbygoogle = window.adsbygoogle || []).push({});

The following user thanked Luulz for this useful post:

Epic?
12-17-2011, 11:04 PM #11
Luulz
Bounty hunter
Originally posted by Epic
So I upgraded it to Python 3 and generally improved it a little bit, if anyone would prefer to be able to run it on the current version of Python:
    
import sys, urllib.request


For those who don't have Python: You must login or register to view this content.
Just copy the code into a file, extension .py, then run it on the python interpreter: python filename website from the command line.

You can give You must login or register to view this content. a try if you're looking for a vulnerable site to test it on.


I Was actually testing that website, and it doesnt seem to be injectable because something else, still doesnt mean its not vulnerable, just need more advanced teqnuies.
proof of concept:
You must login or register to view this content. union all select 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47--
12-17-2011, 11:07 PM #12
Epic?
Awe-Inspiring
Originally posted by Luulz View Post
I Was actually testing that website, and it doesnt seem to be injectable because something else, still doesnt mean its not vulnerable, just need more advanced teqnuies.
proof of concept:
You must login or register to view this content. union all select 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47--


I'll be honest, it might not be vulnerable. I just found it on a list of vulnerable sites on HF, ran it through the scanner, and it flagged it as vulnerable. I figured that way people might at least have something to try out.
12-17-2011, 11:14 PM #13
Luulz
Bounty hunter
Originally posted by Epic
I'll be honest, it might not be vulnerable. I just found it on a list of vulnerable sites on HF, ran it through the scanner, and it flagged it as vulnerable. I figured that way people might at least have something to try out.


i remember people on HF called be a skid, and accused me for using Havij until i gave them links. LMAO

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo