mirror of
https://github.com/byt3bl33d3r/MITMf.git
synced 2025-08-20 21:43:28 -07:00
Added error handling to DNS and SMB servers when port is in use
Added check to see if a plugins options were called without loading the actual plugin
This commit is contained in:
parent
70ec5a2bbc
commit
d3e509d4cd
10 changed files with 45 additions and 23 deletions
|
@ -474,10 +474,14 @@ class DNSChef(ConfigWatcher):
|
|||
self.onConfigChange()
|
||||
self.startConfigWatch()
|
||||
|
||||
if self.config['MITMf']['DNS']['tcp'].lower() == 'on':
|
||||
self.startTCP()
|
||||
else:
|
||||
self.startUDP()
|
||||
try:
|
||||
if self.config['MITMf']['DNS']['tcp'].lower() == 'on':
|
||||
self.startTCP()
|
||||
else:
|
||||
self.startUDP()
|
||||
except socket.error as e:
|
||||
if "Address already in use" in e:
|
||||
sys.exit("\n[-] Unable to start DNS server on port {}: port already in use".format(self.config['MITMf']['DNS']['port']))
|
||||
|
||||
# Initialize and start the DNS Server
|
||||
def startUDP(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue