Page 1 of 1

bat obfuscation with set ***=****

Posted: 04 Nov 2019 10:22
by EN3Kz
SET **.=S
%**.%ET .**=E
%**.%%.**%T *.*=T
%**.%%.**%%*.*% ***==
%**.%%.**%%*.*% .F.U.C.K.E.D.%***%%**.%
%.F.U.C.K.E.D.%%.**%%*.*% ..FU.C.K.E.D.%***%%.**%
%.F.U.C.K.E.D.%%..FU.C.K.E.D.%%*.*% ...FUC.K.E.D.%***%%*.*%

just an example you can mix it up with goto`s and %*%
Remember both %**.% & %.F.U.C.K.E.D.% will be read as "S"
So with two variables you can mix it up and help throw off script kitties :lol:

Re: bat obfuscation with set ***=****

Posted: 06 Nov 2019 15:46
by bakemonogatari
in a bat file, do i need an escape character ?

ex:
SET **.=S
echo **. var %**.%
PAUSE

the %**.% only show *. not S

Re: bat obfuscation with set ***=****

Posted: 14 Nov 2019 11:49
by aGerman
Still no feedback from the OP?

@bakemonogatari No escape character will help here. You simply have to use alpha characters rather than asterisks. Why? That's why:
%**.%
As soon as the cmd sees sequence %* it will try to expand it to the passed arguments. If no arguments have been passed to your script, this sequence expands to nothing. *.% is printed as *. because a standing alone percent sign is automatically removed.

Steffen

Re: bat obfuscation with set ***=****

Posted: 19 Nov 2019 15:24
by Squashman

Re: bat obfuscation with set ***=****

Posted: 19 Nov 2019 16:10
by jeb
It's possible to expand a variable, begining with an asterix.

Code: Select all

set **.=SSS
setlocal DisableExtensions
echo %**.%
jeb

Re: bat obfuscation with set ***=****

Posted: 23 Nov 2019 08:00
by bakemonogatari
thanks for explanations.