1
0
mirror of https://github.com/kellyjonbrazil/jc.git synced 2025-07-17 01:32:37 +02:00
This commit is contained in:
Kelly Brazil
2020-02-27 15:26:09 -08:00
parent 61257e7525
commit 997b269b0b

View File

@ -87,7 +87,7 @@ def parse(data, raw=False, quiet=False):
for entry in cleandata: for entry in cleandata:
output_line = {} output_line = {}
if entry.startswith('wtmp begins '): if entry.startswith('wtmp begins ') or entry.startswith('btmp begins '):
continue continue
entry = entry.replace('system boot', 'system_boot') entry = entry.replace('system boot', 'system_boot')
@ -103,7 +103,6 @@ def parse(data, raw=False, quiet=False):
output_line['login'] = ' '.join(linedata[3:7]) output_line['login'] = ' '.join(linedata[3:7])
if len(linedata) > 8: if len(linedata) > 8:
print(linedata)
output_line['logout'] = linedata[8] output_line['logout'] = linedata[8]
if len(linedata) > 9: if len(linedata) > 9: