6
6
from lib .core .discovered_host import *
7
7
8
8
9
-
10
9
class virtual_host_scanner (object ):
11
10
"""Virtual host scanning class
12
11
@@ -20,16 +19,13 @@ class virtual_host_scanner(object):
20
19
ignore_content_length: integer value of content length to ignore
21
20
output: folder to write output file to
22
21
"""
23
-
22
+
23
+
24
24
def __init__ (self , target , wordlist , ** kwargs ):
25
25
self .target = target
26
26
self .wordlist = wordlist
27
- self .unique_depth = unique_depth
28
- self .ssl = ssl
29
- self .fuzzy_logic = fuzzy_logic
30
- self .rate_limit = rate_limit
31
- self .add_waf_bypass_headers = add_waf_bypass_headers
32
27
self .base_host = kwargs .get ('base_host' )
28
+ self .rate_limit = int (kwargs .get ('rate_limit' , 0 ))
33
29
self .port = int (kwargs .get ('port' , 80 ))
34
30
self .real_port = int (kwargs .get ('real_port' , 80 ))
35
31
self .ignore_content_length = int (kwargs .get ('ignore_content_length' , 0 ))
@@ -56,6 +52,7 @@ def ignore_http_codes(self):
56
52
def ignore_http_codes (self , codes ):
57
53
self ._ignore_http_codes = [int (code ) for code in codes .replace (' ' , '' ).split (',' )]
58
54
55
+
59
56
def scan (self ):
60
57
if not self .base_host :
61
58
self .base_host = self .target
@@ -117,7 +114,7 @@ def scan(self):
117
114
118
115
# add url and hash into array for likely matches
119
116
self .results .append (hostname + ',' + page_hash )
120
-
117
+
121
118
#rate limit the connection, if the int is 0 it is ignored
122
119
time .sleep (self .rate_limit )
123
120
0 commit comments