/artifacts/definitions/Windows/EventLogs/Symantec.yaml

https://github.com/Velocidex/velociraptor · YAML · 55 lines · 49 code · 6 blank · 0 comment · 0 complexity · 2c5d11f7406b361fdb0370ac1407d309 MD5 · raw file

  1. name: Windows.EventLogs.Symantec
  2. description: |
  3. Query the Symantec Endpoint Protection Event Logs. The default artifact will
  4. return EventId 51 and high value strings with goals bubble up some events for
  5. triage.
  6. Note:
  7. EventID selection is controlled by regex to allow multiple EID selections.
  8. If running a hunt, consider also hunting EventId 45 - Tamper Protection
  9. Detection (this will be noisy so whitelist is required).
  10. IgnoreRegex allows filtering out events relevant to the target environment.
  11. reference:
  12. - https://www.nextron-systems.com/wp-content/uploads/2019/10/Antivirus_Event_Analysis_CheatSheet_1.7.2.pdf
  13. author: Matt Green - @mgreen27
  14. parameters:
  15. - name: SymantecEventLog
  16. default: C:\Windows\system32\winevt\logs\Symantec Endpoint Protection Client.evtx
  17. - name: RegexEventIds
  18. description: "Regex of Event IDs to hunt for. Consider EID 45 for Tamper Protection Detection"
  19. default: ^51$
  20. - name: TargetRegex
  21. description: "Regex to hunt for - default is high value SEP detections"
  22. default: "Infostealer|Hacktool|Mimi|SecurityRisk|WinCredEd|NetCat|Backdoor|Pwdump|SuperScan|XScan|PasswordRevealer|Trojan|Malscript|Agent|Malware|Exploit|webshell|cobalt|Mpreter|sploit|Meterpreter|RAR|7z|encrypted|tsclient|PerfLogs"
  23. - name: IgnoreRegex
  24. description: "Regex to ignore events with EventData strings matching."
  25. - name: DateAfter
  26. type: timestamp
  27. description: "search for events after this date. YYYY-MM-DDTmm:hh:ssZ"
  28. - name: DateBefore
  29. type: timestamp
  30. description: "search for events before this date. YYYY-MM-DDTmm:hh:ssZ"
  31. sources:
  32. - queries:
  33. - LET DateAfterTime <= if(condition=DateAfter,
  34. then=timestamp(epoch=DateAfter), else=timestamp(epoch="1600-01-01"))
  35. - LET DateBeforeTime <= if(condition=DateBefore,
  36. then=timestamp(epoch=DateBefore), else=timestamp(epoch="2200-01-01"))
  37. - SELECT timestamp(epoch=System.TimeCreated.SystemTime) As EventTime,
  38. System.EventID.Value as EventId,
  39. System.Computer as Computer,
  40. EventData.Data[0] as EventData
  41. FROM parse_evtx(filename=SymantecEventLog)
  42. WHERE
  43. EventTime < DateBeforeTime AND
  44. EventTime > DateAfterTime AND
  45. format(format="%v",args=System.EventID.Value) =~ RegexEventIds AND
  46. EventData =~ TargetRegex AND
  47. if(condition=IgnoreRegex,
  48. then= NOT EventData=~IgnoreRegex,
  49. else= True)