.
677 |
678 |
679 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | SQLiScan
2 |
3 |
4 | An open-source SQL injection Scanner.
5 |
6 | ## Developer
7 | This tool was developed by Kumaraguru (www.kumaraguru.tech) (www.linkedin.com/in/kumaraguru7)
8 |
9 | ## Disclaimer
10 | This tool is developed only for educational purposes. The developer is not responsible if you use this tool for any illegal activities.
11 |
12 | ## How It Works
13 | The python script examines the header responses from the search results of google and based on the response , the tool classifies the vulnerable and non-vulnerable sites.
14 |
15 |
16 | ## Features:
17 |
18 | - Automatically find vulnerable sites using Google Dorks.
19 | - Automatic filtering of irrelevant sites.
20 | - Text file with vulnerable site list can be obtained.
21 | - Automatic VPN Detection.
22 | - Can be useful for mass defacement attacks.
23 | - Useful for bug bounties.
24 | - Easy to use.
25 | - Light weight.
26 | - User friendly.
27 |
28 | ## Instructions to use:
29 |
30 | Run these commands to use SQLi
31 |
32 | ### > For Termux:
33 |
34 | To use the SQLiScan type the following commands in Termux:
35 | ```
36 | pkg install git
37 | pkg install python
38 | git clone https://github.com/hackyguru/SQLiScan
39 | cd SQLiScan
40 | pip install -r requirements.txt
41 | python3 SQLiScan.py
42 | ```
43 |
44 | ### > For Linux/Windows:
45 |
46 | **Notice:**
47 |
48 | To use the scanner type the following commands in Linux/Bash terminal:
49 | ```
50 | git clone https://github.com/hackyguru/SQLiScan
51 | cd SQLiScan
52 | pip install -r requirements.txt
53 | python3 SQLiScan.py
54 | ```
55 |
56 | ## Whats next for SQLiScan
57 | I will be probably adding a GUI for this project in the near future in SQLiScan 2.0. Please hang on until that :D I hope it works well in CLI.
58 |
59 |
60 | ## CONTACT ME:
61 | You can hit me up anytime :grinning:
62 |
63 | Instagram : www.instagram.com/guru.317
64 | Portfolio : www.kumaraguru.tech
65 | LinkedIn : www.linkedin.com/in/kumaraguru7
--------------------------------------------------------------------------------
/SQLiScan.py:
--------------------------------------------------------------------------------
1 | #This Tool was developed by Kumaraguru (www.github.com/hackyguru)
2 | #Please refrain from changing content and removing credits
3 |
4 |
5 | # Imports
6 | from googlesearch import search
7 | import time
8 | import requests
9 | import os
10 |
11 | # Installing dependency
12 | os.system("apt install toilet -y")
13 |
14 | # Functions
15 | def checkvpn():
16 | c=os.system("ifconfig tun0")
17 | os.system("clear")
18 | if(c==0):
19 | banner()
20 | print("")
21 | else:
22 | banner()
23 | print("\033[1;31;40mYour VPN is not recommended to be used.")
24 | print("")
25 | def banner():
26 | os.system("clear")
27 | os.system("toilet -fmono12 -F gay SQLiScan")
28 | print(" \033[1;36;40m Developed by: \033[1;32;40m Kumaraguru")
29 | print(" \033[1;36;40m Instagram : \033[1;32;40m www.instagram.com/guru.317")
30 | print(" \033[1;36;40m Github : \033[1;32;40m www.github.com/hackyguru")
31 | print(" \033[1;36;40m Linked In : \033[1;34;40m www.linkedin.com/in/kumaraguru7")
32 | banner()
33 | checkvpn()
34 | headers={'User-Agent':'Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:75.0) Gecko/20100101 Firefox/75.0'}
35 | q=str(input("\033[1;33;40mEnter a dork: "))
36 | no=int(input("\033[1;33;40mEnter the number of results you wish to search: "))
37 | times=int(input("\033[1;33;40mEnter the timeout :"))
38 | op=str(input("\033[1;33;40mDo you want to save the vulnerable sites as txt file(Y/n) :"))
39 | if(op=="Y" or op=="y"):
40 | name=str(input("\033[1;33;40mEnter the name of your output txt file :"))
41 | print("\033[1;32;40mAll vulnerable URLs will be saved in "+name)
42 | time.sleep(2)
43 | f=open(name,"a+")
44 | i=1
45 | banner()
46 | checkvpn()
47 | for url in search(q,tld="com",num=no,stop=no,pause=2):
48 | if("php?" not in url):
49 | i=i+1
50 | continue
51 | print("\033[1;37;40m"+str(i)+". \033[1;35;40mChecking the URL: ")
52 | print("\033[1;34;40m"+url)
53 | try:
54 | checkurl=url+"%27"
55 | r=requests.get(url,headers=headers,timeout=times)
56 | s=requests.get(checkurl,headers=headers,timeout=times)
57 | if((s.url != checkurl) or ("af.org.pk" in url)):
58 | print("\033[1;31;40mNot Vulnerable!\n")
59 | i=i+1
60 | continue
61 | if(r.text==s.text):
62 | print("\033[1;31;40mNot Vulnerable!\n")
63 | else:
64 | print("\033[1;32;40mVulnerable.\n")
65 | if(op=="Y" or op=="y"):
66 | f.write(url+"\n")
67 | except:
68 | print("\033[1;31;40mThis site can't be reached now.")
69 | print("")
70 | i=i+1
71 | try:
72 | f.close()
73 | print("\033[1;32;40mVulnerable URLs are saved in "+name)
74 | except:
75 | pass
76 |
77 | # End
--------------------------------------------------------------------------------
/requirements.txt:
--------------------------------------------------------------------------------
1 | requests==2.21.0
2 | google==2.0.3
3 |
4 |
--------------------------------------------------------------------------------