Projects STRLCPY LogonTracer Commits 016f1026
🤬
  • ■ ■ ■ ■ ■ ■
    logontracer.py
    skipped 914 lines
    915 915   category = data.text
    916 916   if data.get("Name") in "SubcategoryGuid" and data.text is not None and re.search(r"\A{[\w\-]*}\Z", data.text):
    917 917   guid = data.text
    918  - policylist.append([etime.strftime("%Y-%m-%d %H:%M:%S"), username, category, guid.lower(), int(stime.strftime("%s"))])
     918 + policylist.append([etime.strftime("%Y-%m-%d %H:%M:%S"), username, category, guid.lower(), int(stime.timestamp())])
    919 919   ###
    920 920   # Detect added users from specific group
    921 921   # EventID 4728: A member was added to a security-enabled global group
    skipped 99 lines
    1021 1021   if username != "-" and username != "anonymous logon" and ipaddress != "::1" and ipaddress != "127.0.0.1" and (ipaddress != "-" or hostname != "-"):
    1022 1022   # generate pandas series
    1023 1023   if ipaddress != "-":
    1024  - event_series = pd.Series([eventid, ipaddress, username, logintype, status, authname, int(stime.strftime("%s"))], index=event_set.columns)
     1024 + event_series = pd.Series([eventid, ipaddress, username, logintype, status, authname, int(stime.timestamp())], index=event_set.columns)
    1025 1025   ml_series = pd.Series([etime.strftime("%Y-%m-%d %H:%M:%S"), username, ipaddress, eventid], index=ml_frame.columns)
    1026 1026   else:
    1027  - event_series = pd.Series([eventid, hostname, username, logintype, status, authname, int(stime.strftime("%s"))], index=event_set.columns)
     1027 + event_series = pd.Series([eventid, hostname, username, logintype, status, authname, int(stime.timestamp())], index=event_set.columns)
    1028 1028   ml_series = pd.Series([etime.strftime("%Y-%m-%d %H:%M:%S"), username, hostname, eventid], index=ml_frame.columns)
    1029 1029   # append pandas series to dataframe
    1030 1030   event_set = event_set.append(event_series, ignore_index=True)
    skipped 435 lines
    1466 1466   username = "-"
    1467 1467   category = event.event_data.CategoryId
    1468 1468   guid = event.event_data.SubcategoryGuid
    1469  - policylist.append([etime.strftime("%Y-%m-%d %H:%M:%S"), username, category, guid.lower(), int(stime.strftime("%s"))])
     1469 + policylist.append([etime.strftime("%Y-%m-%d %H:%M:%S"), username, category, guid.lower(), int(stime.timestamp())])
    1470 1470   ###
    1471 1471   # Detect added users from specific group
    1472 1472   # EventID 4728: A member was added to a security-enabled global group
    skipped 93 lines
    1566 1566   if username != "-" and username != "anonymous logon" and ipaddress != "::1" and ipaddress != "127.0.0.1" and (ipaddress != "-" or hostname != "-"):
    1567 1567   # generate pandas series
    1568 1568   if ipaddress != "-":
    1569  - event_series = pd.Series([eventid, ipaddress, username, logintype, status, authname, int(stime.strftime("%s"))], index=event_set.columns)
     1569 + event_series = pd.Series([eventid, ipaddress, username, logintype, status, authname, int(stime.timestamp())], index=event_set.columns)
    1570 1570   ml_series = pd.Series([etime.strftime("%Y-%m-%d %H:%M:%S"), username, ipaddress, eventid], index=ml_frame.columns)
    1571 1571   else:
    1572  - event_series = pd.Series([eventid, hostname, username, logintype, status, authname, int(stime.strftime("%s"))], index=event_set.columns)
     1572 + event_series = pd.Series([eventid, hostname, username, logintype, status, authname, int(stime.timestamp())], index=event_set.columns)
    1573 1573   ml_series = pd.Series([etime.strftime("%Y-%m-%d %H:%M:%S"), username, hostname, eventid], index=ml_frame.columns)
    1574 1574   # append pandas series to dataframe
    1575 1575   event_set = event_set.append(event_series, ignore_index=True)
    skipped 283 lines
Please wait...
Page is in error, reload to recover