davehull / Kansa

A Powershell incident response framework
Apache License 2.0
1.56k stars 266 forks source link

Get-WebrootListing.ps1 output needs to be ASCII encoded #119

Open jt-msft opened 9 years ago

jt-msft commented 9 years ago

Received an error from Logparser when trying to analyze output from Get-WebrootListing.ps1 module that "some bytes remained undecoded" which blocked results. Re-encoding the output files to ASCII allowed Logparser to read them correctly.

Probably a bug in Logparser, but we can implement a workaround here.

davehull commented 9 years ago

Can you try adding this line before the objects are returned and see if it fixes it? I don't have a web server handy to test against:

$OutputEncoding = [System.Text.Encoding]::ASCII