Skip to content

Commit

Permalink
More filtering on the lines.
Browse files Browse the repository at this point in the history
  • Loading branch information
kiarn committed Jul 18, 2024
1 parent ea092e7 commit b721aa9
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def check_audit_level():

def format_log_data(entry):
data = re.findall(r"\[([^\]]*)\]", entry)
if "@" in data[2]:
if len(data) > 1 and "Kerberos" in data[0] and "@" in data[2]:
date = datetime.strptime(data[3].split(".")[0], "%a, %d %b %Y %H:%M:%S")
return {
'user': data[2].split("@")[0].strip('\\\\'),
Expand Down

0 comments on commit b721aa9

Please sign in to comment.