Beispiel #1
0
 def __init__(self):
     """Initialize a new Nmap OS DB instance"""
     Database.__init__(self)
     self._item_title = None
     self.fields_map = {
         'title': 'n_title',
         'vendor': 'n_vendor',
         'product': 'n_product',
         'version': 'n_version',
         'devtype': 'n_devtype'
     }
     self._search_fields = ['title']
Beispiel #2
0
 def __init__(self):
     """
     """
     Database.__init__(self)
     self.fields_map = {
         'title': 'cpe_title',
         'name': 'cpe_name',
         'part': 'cpe_part',
         'vendor': 'cpe_vendor',
         'product': 'cpe_product',
         'version': 'cpe_version',
         'update': 'cpe_update',
         'edition': 'cpe_edition',
         'language': 'cpe_language'
     }
     self._search_fields = ['title', 'name']
Beispiel #3
0
 def start(self, args):
     """Reset existing DB if exists and setup a new empty one."""
     print '[+] Initializing the whole database...'
     db = Database()
     db.initialize()
     print '[+] Done! You should now run "labctl update all" to populate the DB'