added packet http info into sniffkin3 json log

This commit is contained in:
mh4x0f 2020-04-09 20:02:03 -03:00
parent 7fdedfea8e
commit 89f1bd8fe3
3 changed files with 7 additions and 2 deletions

View File

@ -7,6 +7,7 @@ All notable changes to this project will be documented in this file.
## [1.0.0] - 2020-04-02 ## [1.0.0] - 2020-04-02
### Added ### Added
- added packet http info into sniffkin3 json log [mh4x0f]
- added alert when the client left the ap [mh4x0f] - added alert when the client left the ap [mh4x0f]
- added exceptions implementation error [mh4x0f] - added exceptions implementation error [mh4x0f]
- added license header __init__ file [mh4x0f] - added license header __init__ file [mh4x0f]

View File

@ -82,8 +82,9 @@ class Sniffkin3(MitmMode):
def LogOutput(self,data): def LogOutput(self,data):
if self.conf.get('accesspoint', 'status_ap', format=bool): if self.conf.get('accesspoint', 'status_ap', format=bool):
self.logger.info('[ {0[src]} > {0[dst]} ] {1[Method]} {1[Host]}{1[Path]}'.format( self.logger.addExtra('packet', data) # packet info save json
data['urlsCap']['IP'], data['urlsCap']['Headers'])) self.logger.info('[ {0[src]} > {0[dst]} ] {1[Method]} {1[Host]}{1[Path]}'
.format(data['urlsCap']['IP'], data['urlsCap']['Headers']))
@property @property
def getPlugins(self): def getPlugins(self):

View File

@ -152,6 +152,9 @@ class StandardLog:
self.configure() self.configure()
self.logger.debug(message) self.logger.debug(message)
def addExtra(self,key=str ,data=dict):
self.extra[key] = data
class LoggerManager(CoreSettings): class LoggerManager(CoreSettings):
Name = "Logger Manager" Name = "Logger Manager"
ID = "Logger" ID = "Logger"