Removed non-ascii character from Get-FoxDump.ps1

Added ascii check before module tasking
1.6
Harmj0y 2015-11-28 20:24:45 -05:00
parent 38ca880cf5
commit 743fe02b44
2 changed files with 7 additions and 1 deletions

View File

@ -1,4 +1,4 @@
Function Get-FoxDump
Function Get-FoxDump
{
<#
.SYNOPSIS

View File

@ -2414,6 +2414,12 @@ class ModuleMenu(cmd.Cmd):
dispatcher.send("[!] Error: module produced an empty script", sender="Empire")
return
try:
moduleData.decode('ascii')
except UnicodeDecodeError:
print helpers.color("[!] Error: module source contains non-ascii characters")
return
# strip all comments from the module
moduleData = helpers.strip_powershell_comments(moduleData)