Skip to content

Instantly share code, notes, and snippets.

@infosec-intern
Created December 9, 2017 22:13
Show Gist options
  • Save infosec-intern/b73dd7b6a823f3c088050617e4a36719 to your computer and use it in GitHub Desktop.
Save infosec-intern/b73dd7b6a823f3c088050617e4a36719 to your computer and use it in GitHub Desktop.
Convert a Windows event log record into a JSON document
# LogName can be any available event log
# or it can be replaced with "-Path" and a file path
# The resulting JSON can then be POSTed to a webserver of your choice
Get-WinEvent -LogName "Security" -MaxEvents 1 | ConvertTo-Json
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment