Commit 6fccdac4 authored by Ad Schellevis's avatar Ad Schellevis

(ids) small improvement on list alertlogs

parent 4f571608
......@@ -42,7 +42,8 @@ result = []
for filename in sorted(glob.glob('%s*'%suricata_alert_log)):
row = dict()
row['size'] = os.stat(filename).st_size
if row['size'] > 0:
# always list first file and non empty next.
if row['size'] > 0 or filename.split('/')[-1].count('.') > 1:
row['modified'] = os.stat(filename).st_mtime
row['filename'] = filename.split('/')[-1]
# try to find actual timestamp from file
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment