Exemplo n.º 1
0
 def __init__(self, parentWidget, parentItem=None, intType=0):
     self.loader = loader()
     if parentItem:
         QTreeWidgetItem.__init__(self, parentItem)
     else:
         QTreeWidgetItem.__init__(self, parentWidget)
     self.parentWidget = parentWidget
Exemplo n.º 2
0
    def __init__(self, parent=None, root=None):
        QWizard.__init__(self, parent)
        Dialog.__init__(self, parent)
        self.mainWindow = parent
        self.setWindowTitle(self.tr("DFF Wizard"))
        self.postProcessAnalysePage = None
        self.root = root

        if not root:
            self.connectorPage = ConnectorPage(self)
            self.localPage = LocalPage(self)
            self.setPage(AutoWizard.Page_Connector, self.connectorPage)
            self.setPage(AutoWizard.Page_Local, self.localPage)
            self.devicePage = DevicePage(self)
            self.setPage(AutoWizard.Page_Device, self.devicePage)

        self.postProcessConfigPage = PostProcessConfigPage(self)
        self.setPage(AutoWizard.Page_PostProcessConfig,
                     self.postProcessConfigPage)

        for module in loader().modules.itervalues():
            if module.tags.lower().find('analyse') != -1:
                self.postProcessAnalysePage = PostProcessAnalysePage(self)
                self.setPage(AutoWizard.Page_PostProcessAnalyse,
                             self.postProcessAnalysePage)
                break
        self.postProcessMode = PostProcessMode(self)
        self.setPage(AutoWizard.Page_PostProcessMode, self.postProcessMode)
        self.endPage = EndPage(self)
        self.setPage(AutoWizard.Page_End, self.endPage)
Exemplo n.º 3
0
Arquivo: modules.py Projeto: kzwkt/dff
 def __init__(self, parent):
     QTreeWidget.__init__(self, parent)
     self.name = "Modules"
     self.tm = TaskManager()
     self.loader = loader.loader()
     self.setupUi(self)
     self.initTreeModule()
Exemplo n.º 4
0
    def __init__(self, parent, mainWindow, tags, selectItem = None):
        QMenu.__init__(self, tags,  parent)
	self.tags = tags
        self.__mainWindow = mainWindow
        self.callbackSelected = selectItem
        self.loader = loader.loader()
        self.Load()
Exemplo n.º 5
0
 def __init__(self):
    Queue.__init__(self)
    self.display = None
    self.count = 0
    self.countLock = threading.Lock()
    self.moduleMapCount  = {}
    self.loader = loader.loader()
Exemplo n.º 6
0
 def __init__(self, parent):
     QTreeWidget.__init__(self, parent)
     self.name = "Modules"
     self.tm = TaskManager()
     self.loader = loader.loader()
     self.setupUi(self)
     self.initTreeModule()
Exemplo n.º 7
0
Arquivo: menu.py Projeto: kzwkt/dff
 def __init__(self, parent, mainWindow, tags, selectItem=None):
     QMenu.__init__(self, tags, parent)
     self.tags = tags
     self.__mainWindow = mainWindow
     self.callbackSelected = selectItem
     self.loader = loader.loader()
     self.Load()
Exemplo n.º 8
0
 def __init__(self):
     EventHandler.__init__(self)
     self.loader = loader.loader()
     self.processusManager = ProcessusManager()
     self.VFS = VFS.Get()
     self.VFS.connection(self)
     self.ppModules = ModulesConfig()
     self.ppAnalyses = ModulesConfig()
Exemplo n.º 9
0
 def __init__(self, console, DEBUG=False, VERBOSITY=0):
     self.DEBUG = DEBUG
     self.VERBOSITY = VERBOSITY
     self.console = console
     self.lp = LineParser(self.DEBUG, self.VERBOSITY - 1)
     self.confmanager = ConfigManager.Get()
     self.loader = loader()
     self.vfs = vfs()
Exemplo n.º 10
0
 def __init__(self):
   EventHandler.__init__(self)
   self.loader = loader.loader()
   self.processusManager = ProcessusManager()
   self.VFS = VFS.Get()
   self.VFS.connection(self)
   self.ppModules = ModulesConfig()
   self.ppAnalyses = ModulesConfig()
Exemplo n.º 11
0
    def __init__(self, console, DEBUG = False, VERBOSITY = 0):
        self.DEBUG = DEBUG
        self.VERBOSITY = VERBOSITY
	self.console = console
        self.lp = LineParser(self.DEBUG, self.VERBOSITY - 1)
        self.confmanager = ConfigManager.Get()
        self.loader = loader()
        self.vfs = vfs()
Exemplo n.º 12
0
 def __init__(self, parent, mainWindow, node = None, selectItem = None):
      QMenu.__init__(self, mainWindow)
      self.loader = loader.loader()
      self.callbackSelected = self.selectNode
      self.parent = parent
      self.mainWindow = mainWindow
      self.node = node
      self.Load()
      actions = []
Exemplo n.º 13
0
 def __init__(self, parent=None):
     QStackedWidget.__init__(self, parent)
     sizePolicy = QSizePolicy(QSizePolicy.MinimumExpanding,
                              QSizePolicy.MinimumExpanding)
     sizePolicy.setVerticalStretch(1)
     self.setSizePolicy(sizePolicy)
     self.currentWidget = None
     self.loader = loader()
     self.moduleName = None
Exemplo n.º 14
0
Arquivo: menu.py Projeto: kzwkt/dff
 def __init__(self, parent, mainWindow, node=None, selectItem=None):
     QMenu.__init__(self, mainWindow)
     self.loader = loader.loader()
     self.callbackSelected = self.selectNode
     self.parent = parent
     self.mainWindow = mainWindow
     self.node = node
     self.Load()
     actions = []
Exemplo n.º 15
0
    def __init__(self, tag, box):
        self.tag = tag
        self.box = box
        self.browser = box.browser
        self.stacked = box.stacked
        self.loader = loader.loader()
        self.itemodules = []

        self.getModules()
        self.listw = None
Exemplo n.º 16
0
    def __init__(self, stacked):
        QListWidget.__init__(self)
        self.stacked = stacked
        self.loader = loader.loader()

        self.setResizeMode(QListView.Adjust)
        self.setMovement(QListView.Static)
        self.setViewMode(QListView.IconMode)

        self.connect(self, SIGNAL("itemPressed(QListWidgetItem *)"),
                     self.GMShape)
Exemplo n.º 17
0
 def __init__(self, IOout = None, debug = False):
   self.lparent = []
   self.debug = debug
   self.oldstdout = sys.__stdout__
   self.oldstderr = sys.__stderr__
   self.ioOut = IOout
   self.processusManager = ProcessusManager()
   self.loader = loader.loader()
   if not self.debug:
     sys.stdout = RedirectWrite(self, 'out')
     sys.stderr = RedirectWrite(self, 'err')
   self.write = sys.stdout.write      
Exemplo n.º 18
0
 def __init__(self, IOout=None, debug=False):
     self.lparent = []
     self.debug = debug
     self.oldstdout = sys.__stdout__
     self.oldstderr = sys.__stderr__
     self.ioOut = IOout
     self.processusManager = ProcessusManager()
     self.loader = loader.loader()
     if not self.debug:
         sys.stdout = RedirectWrite(self, 'out')
         sys.stderr = RedirectWrite(self, 'err')
     self.write = sys.stdout.write
Exemplo n.º 19
0
 def __init__(self, parent=None):
     QTreeWidget.__init__(self, parent)
     sizePolicy = QSizePolicy(QSizePolicy.Preferred,
                              QSizePolicy.MinimumExpanding)
     self.setSizePolicy(sizePolicy)
     self.loader = loader()
     self.taskmanager = TaskManager()
     moduleMap = self.ppModuleMap()
     self.header().hide()
     self.populate(moduleMap)
     self.connect(self, SIGNAL("itemClicked(QTreeWidgetItem*, int)"),
                  self.moduleClicked)
Exemplo n.º 20
0
    def getSetTags():
	lmodules = loader.loader().modules
	setags = set()
	for mod in lmodules:
	  try:
	   setags.add(lmodules[mod].tags) 
	  except AttributeError:
	   pass
  	try :
	   setags.remove('')
	except KeyError:
	   pass
	return setags
Exemplo n.º 21
0
Arquivo: utils.py Projeto: kzwkt/dff
 def getSetTags():
     lmodules = loader.loader().modules
     setags = set()
     for mod in lmodules:
         try:
             setags.add(lmodules[mod].tags)
         except AttributeError:
             pass
     try:
         setags.remove('')
     except KeyError:
         pass
     return setags
Exemplo n.º 22
0
 def __init__(self, selection, listmodel):
     super(QWidget, self).__init__()
     self.setupUi(self)
     self.processusManager = ProcessusManager()
     self.loader = loader.loader()
     self.lmodules = self.loader.modules
     self.taskmanager = TaskManager()
     self.mainwindow = QApplication.instance().mainWindow
     self.createActions()
     self.checkedSelection = selection
     self.selection = None
     self.model = listmodel
     self.bookManager = BookmarkManager(self.model)
Exemplo n.º 23
0
 def __init__(self,  mainWindow):
     QDialog.__init__(self, mainWindow)
     Ui_applyModule.__init__(self)
     self.setupUi(self)
     self.labActivate.setVisible(False)
     self.labType.setVisible(False)
     self.labDescription.setVisible(False)
     self.connect(self.buttonBox,SIGNAL("accepted()"), self.validateModule)
     self.__mainWindow = mainWindow
     self.loader = loader.loader()
     self.vfs = vfs()
     self.valueArgs = {}
     self.translation()
Exemplo n.º 24
0
 def __init__(self, mainWindow):
     QDialog.__init__(self, mainWindow)
     Ui_applyModule.__init__(self)
     self.setupUi(self)
     self.labActivate.setVisible(False)
     self.labType.setVisible(False)
     self.labDescription.setVisible(False)
     self.connect(self.buttonBox, SIGNAL("accepted()"), self.validateModule)
     self.__mainWindow = mainWindow
     self.loader = loader.loader()
     self.vfs = vfs()
     self.valueArgs = {}
     self.translation()
Exemplo n.º 25
0
 def __init__(self, selection, listmodel):
   super(QWidget, self).__init__()
   self.setupUi(self)
   self.processusManager = ProcessusManager()
   self.loader = loader.loader()
   self.lmodules = self.loader.modules
   self.taskmanager = TaskManager()
   self.mainwindow = QApplication.instance().mainWindow
   self.createActions()
   self.checkedSelection = selection
   self.selection = None
   self.model = listmodel
   self.bookManager = BookmarkManager(self.model)
Exemplo n.º 26
0
 def __init__(self, arguments):
     self.arguments = arguments
     if self.arguments:
         self.debug = self.arguments.debug
         self.verbosity = self.arguments.verbosity
     else:
         self.debug = False
         self.verbosity = 0
     RedirectIO(None, self.debug)
     # When UI is initialized from main, arguments are provided
     # When UI is initialized from shell widget, there are no arguments
     if CrashHandlerEnabled and self.arguments and not self.arguments.no_exception_handler:
         self.handler = CrashHandler()
         self.handler.setVersion(VERSION)
         if self.arguments.silent_report:
             self.handler.setSilentReport(True)
         self.handler.setHandler()
     self.loader = loader()
Exemplo n.º 27
0
 def __init__(self, selection, listmodel):
     super(QWidget, self).__init__()
     self.__iconView = False
     self.setupUi(self)
     self.processusManager = ProcessusManager()
     self.loader = loader.loader()
     self.lmodules = self.loader.modules
     self.taskmanager = TaskManager()
     self.mainwindow = QApplication.instance().mainWindow
     self.createActions()
     self.checkedSelection = selection
     self.selection = None
     self.model = listmodel
     self.bookManager = BookmarkManager(self.model)
     #self.document = QtWebKit.QWebView()
     #self.document.loadFinished.connect(self.__print)
     self.__corrupt = base64.b64encode(
         str(QtGui.QImage(":file_broken.png").bits()))
     self.__printer = QtGui.QPrinter(QtGui.QPrinter.ScreenResolution)
     self.__printer.setOutputFormat(QtGui.QPrinter.PdfFormat)
     self.__printer.setPaperSize(QtGui.QPrinter.A4)
     self.__printer.setFullPage(True)
Exemplo n.º 28
0
Arquivo: preview.py Projeto: kzwkt/dff
 def __init__(self, parent):
     QWidget.__init__(self, parent)
     self.layout = QVBoxLayout(self)
     self.layout.setSpacing(0)
     self.layout.setContentsMargins(0, 0, 0, 0)
     self.stack = QStackedWidget(self)
     self.toolBar = QToolBar(self)
     self.connect(self.toolBar, SIGNAL('actionTriggered(QAction*)'),
                  self.clicked)
     self.layout.addWidget(self.toolBar)
     self.layout.addWidget(self.stack)
     self.setLayout(self.layout)
     self.__mainWindow = parent
     self.name = "Preview"
     self.loader = loader()
     self.lmodules = self.loader.modules
     void = QWidget()
     self.previousWidget = void
     self.stack.addWidget(void)
     self.setWindowIcon(QIcon(QPixmap(":viewer.png")))
     self.retranslateUi(self)
     self.previousNode = None
     self.currentNode = None
     self.mustUpdate = True
Exemplo n.º 29
0
 def __init__(self, parent):
     QObject.__init__(self)
     self.parent = parent
     self.vfs = vfs.vfs()
     self.taskmanager = TaskManager()
     self.loader = loader.loader()
Exemplo n.º 30
0
 def __init__(self, parent):
     super(QDialog, self).__init__()
     self.setupUi(self)
     self.loader = loader.loader()
     self.createShape()
Exemplo n.º 31
0
Arquivo: ui.py Projeto: kzwkt/dff
 def __init__(self, debug=False, verbosity=0):
     self.debug = debug
     self.verbosity = verbosity
     RedirectIO(None, self.debug)
     self.loader = loader()
Exemplo n.º 32
0
 def getArgs(modules_name):
     l = loader.loader()
     if type(modules_name) == StringType :
         return l.modules[modules_name].conf.arguments()
     else :
         return None
Exemplo n.º 33
0
# at the top of the source tree.
#
# See http://www.digital-forensic.org for more information about this
# project. Please do not directly contact any of the maintainers of
# DFF for assistance; the project provides a web site, mailing lists
# and IRC channels for your use.
#
# Author(s):
#  Solal Jacob <*****@*****.**>
#
import os, sys

from dff.api.loader.loader import loader

pathset = set()

for moduleDirectory in loader().modulesPaths():
    if moduleDirectory[0] != "/":
        for files in os.listdir(os.getcwd() + "/" + moduleDirectory):
            directory = os.getcwd() + "/" + moduleDirectory + "/" + files
            if os.path.isdir(directory):
                pathset.add(directory[len(os.getcwd()) + 1:])
    else:
        for files in os.listdir(moduleDirectory):
            directory = moduleDirectory + "/" + files
            if os.path.isdir(directory):
                pathset.add(directory)

for path in pathset:
    __path__.append(path)
Exemplo n.º 34
0
 def getArgsDriver(driver_name):
     l = loader.loader()
     return l.getdriver(driver_name).conf.descr_l
Exemplo n.º 35
0
Arquivo: utils.py Projeto: kzwkt/dff
 def getArgsDriver(driver_name):
     l = loader.loader()
     return l.getdriver(driver_name).conf.descr_l
Exemplo n.º 36
0
 def __init__(self):
     Script.__init__(self, "info")
     VariantTreePrinter.__init__(self)
     self.loader = loader.loader()
     self.processusManager = ProcessusManager()
     self.cm = ConfigManager.Get()
Exemplo n.º 37
0
 def __init__(self):
   Script.__init__(self, "info")
   VariantTreePrinter.__init__(self)
   self.loader = loader.loader()
   self.processusManager = ProcessusManager()
   self.cm = ConfigManager.Get()
Exemplo n.º 38
0
# at the top of the source tree.
#  
# See http://www.digital-forensic.org for more information about this
# project. Please do not directly contact any of the maintainers of
# DFF for assistance; the project provides a web site, mailing lists
# and IRC channels for your use.
# 
# Author(s):
#  Solal Jacob <*****@*****.**>
# 
import os, sys

from dff.api.loader.loader import loader

pathset = set()

for moduleDirectory in loader().modulesPaths():
  if moduleDirectory[0] != "/":
    for files in os.listdir(os.getcwd() + "/" + moduleDirectory):
      directory = os.getcwd() + "/" + moduleDirectory + "/" + files
      if os.path.isdir(directory):
        pathset.add(directory[len(os.getcwd()) + 1:]) 
  else:
    for files in os.listdir(moduleDirectory):
      directory = moduleDirectory + "/" + files
      if os.path.isdir(directory):
        pathset.add(directory) 
      
for path in pathset:
  __path__.append(path)
Exemplo n.º 39
0
Arquivo: utils.py Projeto: kzwkt/dff
 def getArgs(modules_name):
     l = loader.loader()
     if type(modules_name) == StringType:
         return l.modules[modules_name].conf.arguments()
     else:
         return None
Exemplo n.º 40
0
Arquivo: ui.py Projeto: arxsys/dff-ui
 def __init__(self, debug = False, verbosity = 0):
  self.debug = debug
  self.verbosity = verbosity
  RedirectIO(None, self.debug)
  self.loader = loader()