forked from JACK-NEW-PROJECT/deletedrepo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ultimate-dork.py
161 lines (142 loc) · 3.79 KB
/
ultimate-dork.py
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
#-*- coding: utf-8 -*-
import sys,argparse
if sys.version[0] in '2':
print('\n[x] Not Supported For python 2.x Please Use Python 3.x \n')
exit()
from lib.tmp import color as _
try:
import mechanicalsoup
import requests
except Exception as e:
print('\n{}[-]{} mechanicalsoup package Not Installed\n'.format(_.R,_.W))
print('type pip3 install mechanicalsoup')
exit()
from lib.lib import Parser
from lib.sqlscan import sqli_scan
from lib.tmp import logo
from lib.tmp import color as c
urls = []
class crawl(object):
auth = {
1:[
'https://www.google.com',
'class="r"><a href="/url\?q=(.*?)&',
'fl'
],
2:[
'https://www.bing.com',
'h=".*?" href="(h.*?")',
"b_widePag sb_bp"
]
}
def __init__(
self,
dork,
proxy = None
):
self.dork = dork
self.proxy = proxy
def Bing(self):
bing = Parser(
self.dork,
crawl.auth[2][0],
crawl.auth[2][1],
crawl.auth[2][2],
proxy = self.proxy
)
bing.request()
for url in dir(bing):
if 'go.microsoft.com' in url or 'bing.com' in url:
pass
else:
urls.append(url)
def Google(self):
google = Parser(
self.dork,
crawl.auth[1][0],
crawl.auth[1][1],
crawl.auth[1][2],
proxy = self.proxy
)
google.request()
for url in dir(google):
if 'go.microsoft.com' in url or 'bing.com' in url:
pass
else:
urls.append(url)
class SQLi_Scanner(sqli_scan):
pass
if sys.version[0] in '2':
print('\n[x] Not Supported For python 2.x Please Use Python 3.x \n')
exit()
fel = sys.argv[0]
par = argparse.ArgumentParser(
prog=fel,
usage="%(prog)s --dork [keyword] --scan",
formatter_class=argparse.RawTextHelpFormatter,
description="""
Descriptions:
* By : 407 Authentic Exploit
-----------------------------:
- Codename : JaxBCD
+ Crawl Web Use Google Dork & Bing Dork
+ with Features SQLi Scanner Vulnerability
""")
par.add_argument(
'--dork',
help="""
Your Dork e.g inurl:.php?id=
""",
metavar='[keywords]',
type=str)
par.add_argument(
'--proxy',
help='''
if using proxy e.g 127.0.0.1:1337
with auth e.g user@pass:127.0.0.1:1337
''',
metavar='[proxy:port]',
type=str,
action='store',
default=None)
par.add_argument(
'--scan',help="if with Scan SQL injection Vulnerability Use This argument",action="store_true")
arg = par.parse_args()
try:
if arg.scan:
if arg.dork != None:
print(logo())
_ = crawl(arg.dork,proxy=arg.proxy)
_.Bing()
_.Google()
if urls != []:
for url in list(set(urls)):
print('- {}'.format(url))
for scan in list(set(urls)):
try:
SQLi_Scanner().scan(scan)
except Exception as e:
print(e)
else:
print('\n{}[-]{} No Url Found !\n'.format(c.R,c.W))
else:
par.print_help()
elif not arg.scan:
if arg.dork != None:
print(logo())
_ = crawl(arg.dork,proxy=arg.proxy)
_.Bing()
_.Google()
if urls != []:
for url in list(set(urls)):
print('- {}'.format(url))
else:
print('\n{}[-]{} No Url Found !\n'.format(c.R,c.W))
else:
par.print_help()
else:
par.print_help()
except Exception as e:
print(e)
except KeyboardInterrupt:
exit()