Skip to content

Commit

Permalink
Merge pull request #536 from YuningMiao/master
Browse files Browse the repository at this point in the history
bugfix for cybercrimetracker
  • Loading branch information
sebdraven authored Nov 8, 2019
2 parents b30b4e0 + 4cc52fc commit 9c59130
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 6 deletions.
2 changes: 1 addition & 1 deletion plugins/feeds/public/cybercrimetracker.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ def update(self):

pub_date = parser.parse(item['pubDate'])
if self.last_run is not None:
if since_last_run > pub_date:
if since_last_run > pub_date.replace(tzinfo=None):
continue

self.analyze(item, pub_date)
Expand Down
13 changes: 10 additions & 3 deletions plugins/feeds/public/malwaremustdiecncs.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,16 @@ def update(self):

for item in self.update_xml('item', ["title", "description"]):
if self.last_run is not None:
if datetime.strptime(item["description"], "%d/%b/%Y") < since_last_run:
continue

try:
if datetime.strptime(item["description"], "%d/%b/%Y") < since_last_run:
continue
except ValueError:
pass
try:
if datetime.strptime(item["description"], "%d/%B/%Y") < since_last_run:
continue
except ValueError:
raise ValueError("couldn't parse date")
self.analyze(item["title"])

def analyze(self, cnc):
Expand Down
4 changes: 2 additions & 2 deletions yeti.conf.sample
Original file line number Diff line number Diff line change
Expand Up @@ -82,5 +82,5 @@
# token =

[otx]
#otx_key = YourOTXKey
#number_page = 1
# otx_key = YourOTXKey
# number_page = 1

0 comments on commit 9c59130

Please sign in to comment.