mirror of
https://github.com/byt3bl33d3r/MITMf.git
synced 2025-07-07 21:42:17 -07:00
session hijack plugin 50% done
This commit is contained in:
parent
e4cf519356
commit
fcbc2254bd
6 changed files with 68 additions and 21 deletions
|
@ -16,7 +16,7 @@
|
|||
# USA
|
||||
#
|
||||
|
||||
import re
|
||||
import re, os
|
||||
|
||||
class URLMonitor:
|
||||
|
||||
|
@ -41,6 +41,22 @@ class URLMonitor:
|
|||
|
||||
return (client,url) in self.strippedURLs
|
||||
|
||||
def writeClientLog(self, client, headers, message):
|
||||
if (client.getClientIP() + '.log') not in os.listdir("./logs"):
|
||||
|
||||
try:
|
||||
log_message = "#Log file for %s (%s)\n" % (client.getClientIP(), headers['user-agent'])
|
||||
except KeyError:
|
||||
log_message = "#Log file for %s\n" % client.getClientIP()
|
||||
|
||||
log_file = open("./logs/" + client.getClientIP() + ".log", 'a')
|
||||
log_file.write(log_message + message + "\n")
|
||||
log_file.close()
|
||||
else:
|
||||
log_file = open("./logs/" + client.getClientIP() + ".log", 'a')
|
||||
log_file.write(message + "\n")
|
||||
log_file.close()
|
||||
|
||||
def getSecurePort(self, client, url):
|
||||
if (client,url) in self.strippedURLs:
|
||||
return self.strippedURLPorts[(client,url)]
|
||||
|
@ -69,12 +85,16 @@ class URLMonitor:
|
|||
self.strippedURLs.add((client, url))
|
||||
self.strippedURLPorts[(client, url)] = int(port)
|
||||
|
||||
def setFaviconSpoofing(self, faviconSpoofing):
|
||||
def setValues(self, faviconSpoofing, clientLogging):
|
||||
self.faviconSpoofing = faviconSpoofing
|
||||
self.clientLogging = clientLogging
|
||||
|
||||
def isFaviconSpoofing(self):
|
||||
return self.faviconSpoofing
|
||||
|
||||
def isClientLogging(self):
|
||||
return self.clientLogging
|
||||
|
||||
def isSecureFavicon(self, client, url):
|
||||
return ((self.faviconSpoofing == True) and (url.find("favicon-x-favicon-x.ico") != -1))
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue