Adding COMPRESS function for easier conversion of multi-line scripts to a one-liner command while drastically reducing the command length for cmd.exe command line length limitation purposes.
Added support for WindowStyle shorthand arguments:
0,n,no,nor,norm,norma
1,h,hi,hid,hidd,hidde
2,mi,min,mini,minim,minimi,minimiz,minimize
3,ma,max,maxi,maxim,maximi,maximiz,maximize
Added support for WindowStyle shorthand arguments:
0,n,no,nor,norm,norma
1,h,hi,hid,hidd,hidde
2,m,mi,min,mini,minim,minimi,minimiz,minimize
3,m,ma,max,maxi,maxim,maximi,maximiz,maximize
Variable token fix: Some variables were being obfuscated without trimming out double quotes (i.e. ${"var`Name"} instead of ${varName})
String token fix: ParameterSetName strings (but not DefaultParameterSetName) string values now error when trying to concatenate or reorder even when encapsulated with curly braces. This fix downgrades these parameter binding scenarios with double quotes and tick markes, same as a member token obfuscation. This was causing errors when obfuscating, for example, Invoke-Mimikatz with any kind of STRING token obfuscation (Token\String\* or Token\All\1).
Variable token fix: Some variables were being obfuscated without trimming out double quotes (i.e. ${"var`Name"} instead of ${varName})
String token fix: ParameterSetName strings (but not DefaultParameterSetName) string values now error when trying to concatenate or reorder even when encapsulated with curly braces. This fix downgrades these parameter binding scenarios with double quotes and tick markes, same as a member token obfuscation. This was causing errors when obfuscating, for example, Invoke-Mimikatz with any kind of STRING token obfuscation (Token\String\* or Token\All\1).
Fixed string obfuscation bug when $ or ` are present in strings encapsulated by double quotes. Also removed white space obfuscation from TOKEN/ALL/1 to dramatically reduce the time required to obfuscate large scripts.
v1.4 - 2016-10-28 BruCON, Ghent: Added new BXOR ENCODING function. Also enhanced
randomized case for all components of all ENCODING functions as well as for
PowerShell execution flags for all LAUNCHERs. Finally, added -EP shorthand option
for -ExecutionPolicy to all LAUNCHERs as well as the optional integer representation
of the -WindowStyle PowerShell execution flag: Normal (0), Hidden (1), Minimized (2),
Maximized (3).