aports/community/adman/heimdal-timestamps.patch

15 lines
525 B
Diff

# Fix heimdal timestamp reading
--- a/adman/kerberos.py
+++ b/adman/kerberos.py
@@ -157,7 +157,9 @@ def parse_klist_output(output):
if line.startswith('\t'):
return handle_ticket
- parts = line.split(' ')
+ # The Heimdal timestamps look like 'Jun 8 14:00:01 2022' with a double blank on position 4
+ # To circumvent this issue we use re.match instead of split
+ parts = re.match(r'(.+)\s\s([^\d].+)\s\s([^\d].+)',line).groups()
issued = parse_time(parts[0])