Commit e878f1e1 authored by PidgeyL's avatar PidgeyL
Browse files

file structure update

parent 52b1597c
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -16,7 +16,7 @@ import argparse
import json
from bson import json_util

from lib import CVEs
import lib.CVEs as cves
from lib.Config import Configuration

# connect to db
@@ -40,7 +40,7 @@ rankinglookup = args.r
vfeedlookup = args.v
capeclookup = args.c

l = CVEs.last(rankinglookup=rankinglookup, vfeedlookup=vfeedlookup, capeclookup=capeclookup)
l = cves.last(rankinglookup=rankinglookup, vfeedlookup=vfeedlookup, capeclookup=capeclookup)

for cveid in dumpallcveid():
    item = l.getcve(cveid=cveid)
+0 −0

File moved.

+0 −0

File moved.

+4 −3
Original line number Diff line number Diff line
@@ -22,8 +22,9 @@ sys.path.append(os.path.join(runPath, ".."))

import argparse

from lib import CVEs
import lib.CVEs as cves 
from lib.Config import Configuration
from lib.ProgressBar import progressbar

# connect to db
db = Configuration.getMongoConnection()
@@ -35,7 +36,7 @@ argParser.add_argument('-l', default=None, help='Number of last entries to index
argParser.add_argument('-n', action='store_true', default=False, help='lookup complete cpe (Common Platform Enumeration) name for vulnerable configuration to add in the index')
args = argParser.parse_args()

c = CVEs.last(namelookup=args.n)
c = cves.last(namelookup=args.n)

indexpath = Configuration.getIndexdir()

@@ -69,7 +70,7 @@ def getcve(cveid=None):
        return False
    return collection.find_one({'id': cveid})

for cveid in dumpallcveid(entry=args.l):
for cveid in progressbar(dumpallcveid(entry=args.l),prefix="Processing"):
    writer = ix.writer()
    item = getcve(cveid=cveid)
    title = item['summary'][0:70]
+0 −0

File moved.

Loading