Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Contact

Shell 

Batch, obfuscated polymorphic engine.

Hey guys. Grab from the link if you need it, there should be instructions within the file itself.

Textuploader.com/5b446
If anyone is wondering how it works, it first sets a bunch of variables for every letter in the alphabet, and then uses those variables to create a vbs script which reads the batch file and replaces the variable names with a new random name.
(Oct 1, 2016 11:01 AM)WOLGA Wrote:  If anyone is wondering how it works, it first sets a bunch of variables for every letter in the alphabet, and then uses those variables to create a vbs script which reads the batch file and replaces the variable names with a new random name.

Yup
It replaces more than just variables, anything you type in the area displayed will be changed.


(Oct 1, 2016 11:01 AM)WOLGA Wrote:  If anyone is wondering how it works, it first sets a bunch of variables for every letter in the alphabet, and then uses those variables to create a vbs script which reads the batch file and replaces the variable names with a new random name.

You do realize that I'm not like trying to have a competition with you right? I'm just posting code, if it's an actual problem I'll go, but still I don't get the whole beef thing.
Dear OP, please stop posting this LQ content. It's seriously damaging the quality of this thread.
Just tell me how and I will.
(Oct 1, 2016 11:54 AM)Zask3333 Wrote:  You do realize that I'm not like trying to have a competition with you right? I'm just posting code, if it's an actual problem I'll go, but still I don't get the whole beef thing.

What makes you think that I think that you want to compete with me? I don't give a shit about you or your letter substitutions. I care that you're bringing down the quality of this section.
(Oct 1, 2016 01:48 PM)JoshuTee Wrote:  Dear OP, please stop posting this LQ content. It's seriously damaging the quality of this thread.

Oh, if that was the problem y'all could have just bluntly said that that was the problem, I don't mind, I thought this was an website where people could upload skips of code without judgement. It's really not a big deal, I just didn't understand what the issue originally was.
I can upload better stuff, I just figured since this was the "batch" session of the website, no one would mind, I have other stuff than batch, these where just some files that I thought that people would like, I still didn't expect criticism from others. There are ways to maturity inform others to up their quality a bit without drama. I'm still very good at vbs/batch/python/autohotkey/and autoit. I don't mind making the encryption from my other post more difficult to solve? I have enough knowledge to fully encrypt a virus (or anything peroid) in more complex ways than this? What is an example of "quality" to you? I can do better than this?


(Oct 1, 2016 03:17 PM)WOLGA Wrote:  What makes you think that I think that you want to compete with me? I don't give a shit about you or your letter substitutions. I care that you're bringing down the quality of this section.

It felt like you was trying to compete by breaking my code, even though the code being broken was never the intention of my post, or in my care at least, if quality was a problem, you could have bluntly stated that earlier, then I would have did an more efficient job, it's not that I can't create something good, I'm new here so I wasn't expecting quality to be an issue, I thought anyone could post here.
(Oct 2, 2016 09:32 AM)Zask3333 Wrote:  Oh, if that was the problem y'all could have just bluntly said that that was the problem, I don't mind, I thought this was an website where people could upload skips of code without judgement. It's really not a big deal, I just didn't understand what the issue originally was.
I can upload better stuff, I just figured since this was the "batch" session of the website, no one would mind, I have other stuff than batch, these where just some files that I thought that people would like, I still didn't expect criticism from others. There are ways to maturity inform others to up their quality a bit without drama. I'm still very good at vbs/batch/python/autohotkey/and autoit. I don't mind making the encryption from my other post more difficult to solve? I have enough knowledge to fully encrypt a virus (or anything peroid) in more complex ways than this? What is an example of "quality" to you? I can do better than this?



It felt like you was trying to compete by breaking my code, even though the code being broken was never the intention of my post, or in my care at least, if quality was a problem, you could have bluntly stated that earlier, then I would have did an more efficient job, it's not that I can't create something good, I'm new here so I wasn't expecting quality to be an issue, I thought anyone could post here.


Well, just because this is the Batch section, it doesn't mean you can post LQ copy pasted non original code here.
You see, what you've claimed to have done for the first time ever has been overdone massively and most older members @ HF are pretty fed up about it.
It's all about originality and creativity! Prove you're an HQ member by creation something awesome, something you really put work in!
Something like a new game, a chatbot, some useful tool! Show us that you CAN code and aren't just a generic skid.
You've also been pretty badly repfucked as I'm currently seeing here. . .
JU
(Oct 2, 2016 11:00 AM)JoshuTee Wrote:  Well, just because this is the Batch section, it doesn't mean you can post LQ copy pasted non original code here.
You see, what you've claimed to have done for the first time ever has been overdone massively and most older members @ HF are pretty fed up about it.
It's all about originality and creativity! Prove you're an HQ member by creation something awesome, something you really put work in!
Something like a new game, a chatbot, some useful tool! Show us that you CAN code and aren't just a generic skid.
You've also been pretty badly repfucked as I'm currently seeing here. . .

But this started all before I posted original source, and posted code that is entirely made by scratch, and I never said I was the first, I said I believed I was. When you say believe, it doesn't mean your entirely sure. This all started when I didn't even do anything wrong.

All I wanted to do was post an encryptor, I don't get the problem when almost all the code was from me. I even said that it wasn't entirely my code, but almost all of it is.

REM "Batch encrypter"
REM UPDATES ON ENCRYPTER
REM ; Variables change with each encryption.
REM ; Generates a separator key from random.
REM ; Creates entirely new encryption scheme each run.
REM ; Decryption key number is more random.
REM ; Now Possible to encrypt entire text files.

REM PROMPT
title Encrypt Batch File
color 0a
@echo off
mode con:cols=50 lines=2
echo Encrypt text files.
pause
cls
mode con:cols=100 lines=2
Setlocal EnableDelayedExpansion

REM RANDOM APLPHABET
set CaseType=97
> Randalphabet.vbs echo randomize timer
>> Randalphabet.vbs echo RandAlphabet=""
>> Randalphabet.vbs echo Do
>> Randalphabet.vbs echo randchar = Chr(Int(26*Rnd+%CaseType%))
>> Randalphabet.vbs echo If Instr(RandAlphabet, randchar) = 0 Then RandAlphabet = RandAlphabet ^& randchar
>> Randalphabet.vbs echo if len(RandAlphabet) = 26 Then exit Do
>> Randalphabet.vbs echo Loop
>> Randalphabet.vbs echo wscript.echo RandAlphabet
for /f "delims=" %%A in ('cscript //nologo Randalphabet.vbs') do set Randalphabet=%%A
del Randalphabet.vbs

REM RANDOM KEY CODE
set /A tbnulamu=%random% %% 3%random:~-1%%random:~-1%

REM RANDOM SEPARATOR GENERATOR
SET /A ht=%random% %% 25
if %ht%==1 goto mm1
if %ht%==2 goto mm1
if %ht%==3 goto mm1
if %ht%==4 goto mm2
if %ht%==5 goto mm2
if %ht%==6 goto mm2
if %ht%==7 goto mm3
if %ht%==8 goto mm3
if %ht%==9 goto mm3
if %ht%==10 goto mm4
if %ht%==11 goto mm4
if %ht%==12 goto mm4
if %ht%==13 goto mm5
if %ht%==14 goto mm5
if %ht%==15 goto mm5
if %ht%==16 goto mm6
if %ht%==17 goto mm6
if %ht%==18 goto mm6
if %ht%==19 goto mm7
if %ht%==20 goto mm7
if %ht%==21 goto mm7
if %ht%==22 goto mm8
if %ht%==23 goto mm8
if %ht%==24 goto mm8
if %ht%==25 goto mm9
:mm1
set separator=È
goto endht
:mm2
set separator=É
goto endht
:mm3
set separator=»
goto endht
:mm4
set separator=¼
goto endht
:mm5
set separator=º
goto endht
:mm6
set separator=Í
goto endht
:mm7
set separator=¿
goto endht
:mm8
set separator=¹
goto endht
:mm9
set separator=µ
goto endht
:mm10
set separator=Ø
goto endht
:mm11
set separator=¸
goto endht
:mm12
set separator=Ð
goto endht
:mm13
set separator=×
goto endht
:mm14
set separator=Ù
goto endht
:mm15
set separator=Ï
goto endht
:mm16
set separator=Ô
goto endht
:mm17
set separator=´
goto endht
:mm18
set separator=Ñ
goto endht
:mm19
set separator=½
goto endht
:mm20
set separator=³
goto endht
:mm21
set separator=Ò
goto endht
:mm22
set separator=¾
goto endht
:mm23
set separator=Ï
goto endht
:mm24
set separator=Ä
goto endht
:mm25
set separator=¶
:endht

REM OPTIONS
:opt
set /P "FILEA= Enter the name of the text file (.txt) that you wish to encrypt (Example; "Somefile.txt") : "
cls
if not exist %FILEA%.txt echo The file "%FILEA%.txt" does not exist. & pause & cls & goto opt
set /P "FILEB= Enter the name of the decrypter that will be generated (Example; "Decrypter") : "
cls


REM ENCRYPTION
echo @ECHO Off > "%FILEB%.bat"
Setlocal EnableExtensions
for /f "delims=" %%A in (%FILEA%.txt) do (
Set /a C+=1
Set X[!C!]=%%A
set djnqhv=%%A
set fhoeuouc=%%B
set dlahkruktj=0123456789%Randalphabet%
for /l %%C in (10 1 36) do (
for /f %%D in ("!dlahkruktj:~%%C,1!") do (
set /a ffjhoedt=%%C*%tbnulamu%
for /f %%E in ("!ffjhoedt!") do (
set "djnqhv=!djnqhv:%%D=%separator%%%E!"
)
)
)
echo echo !djnqhv! ^>^> btpfjjgtlkjvug.nsltcmaipoinmt >> "%FILEB%.bat"
)

REM DECRYPTOR
echo Setlocal EnableExtensions EnableDelayedExpansion >> "%FILEB%.bat"
echo for /f "delims=" %%%%A in (btpfjjgtlkjvug.nsltcmaipoinmt) do ( >> "%FILEB%.bat"
Setlocal DisableExtensions DisableDelayedExpansion
echo Set /a C+=1 >> "%FILEB%.bat"
echo Set X[!C!]=%%%%A >> "%FILEB%.bat"
echo set djnqhv=%%%%A >> "%FILEB%.bat"
echo set fhoeuouc=%%%%B >> "%FILEB%.bat"
echo set dlahkruktj=0123456789%Randalphabet% >> "%FILEB%.bat"
echo for /l %%%%C in (10 1 36) do ( >> "%FILEB%.bat"
echo for /f %%%%D in ("!dlahkruktj:~%%%%C,1!") do ( >> "%FILEB%.bat"
echo set /a ffjhoedt=%%%%C*%tbnulamu% >> "%FILEB%.bat"
echo for /f %%%%E in ("!ffjhoedt!") do ( >> "%FILEB%.bat"
echo set "djnqhv=!djnqhv:%%%%E=%%%%D!" >> "%FILEB%.bat"
echo ) >> "%FILEB%.bat"
echo ) >> "%FILEB%.bat"
echo ) >> "%FILEB%.bat"
echo for /f %%%%F in ("!djnqhv!") do ( >> "%FILEB%.bat"
echo set "djnqhv=!djnqhv:%separator%=!" >> "%FILEB%.bat"
Setlocal EnableExtensions EnableDelayedExpansion
echo echo ^^!djnqhv^^! >> "%FILEB%.bat"
echo ) >> "%FILEB%.bat"
echo ) >> "%FILEB%.bat"
echo del btpfjjgtlkjvug.nsltcmaipoinmt >> "%FILEB%.bat"
echo echo. >> "%FILEB%.bat"
echo set X >> "%FILEB%.bat"
echo pause >> "%FILEB%.bat"

REM CHANGE VARIABLES
echo randomize > "sathha.vbs"
echo set vigdgkdjcduh=createobject("scripting.filesystemobject") >> "sathha.vbs"
echo set meudbk=vigdgkdjcduh.opentextfile(%0,1) >> "sathha.vbs"
echo itbccvdaucgacj=meudbk.readall >> "sathha.vbs"
echo lnbsst="btpfjjgtlkjvug nsltcmaipoinmt tbnulamu nmuler mmdsakuk dlahkruktj ffjhoedt fhoeuouc djnqhv obnqrgvu itbccvdaucgacj lnbsst saaogeagnsoovp srkqaj faevll raiolsdokhbgam vigdgkdjcduh meudbk sathha":saaogeagnsoovp=split(lnbsst," ") >> "sathha.vbs"
echo for each srkqaj in saaogeagnsoovp >> "sathha.vbs"
echo for faevll=1 to int(rnd*6)+2 >> "sathha.vbs"
echo raiolsdokhbgam=raiolsdokhbgam+chr((int(rnd*22)+97))+chr(int(rnd*22)+97) >> "sathha.vbs"
echo next >> "sathha.vbs"
echo itbccvdaucgacj=replace(itbccvdaucgacj,srkqaj,raiolsdokhbgam):raiolsdokhbgam="" >> "sathha.vbs"
echo next >> "sathha.vbs"
echo set meudbk=vigdgkdjcduh.opentextfile(%0,2,1) >> "sathha.vbs"
echo meudbk.writeline itbccvdaucgacj >> "sathha.vbs"
echo meudbk.close >> "sathha.vbs"
REM RUNS THE FILE "mmdsakuk.bat" INVISIBLY.
echo Set WshShell = CreateObject("WScript.Shell") > "nmuler.vbs"
echo WshShell.Run chr(34) ^& "mmdsakuk.bat" ^& Chr(34), 0 >> "nmuler.vbs"
echo Set WshShell = Nothing >> "nmuler.vbs"

REM BATCH FILE TO DELETE TEMPARARY FILES. ("mmdsakuk.bat")
echo @echo off > "mmdsakuk.bat"
echo time out /t 1 /nobreak >> "mmdsakuk.bat"
echo del nmuler.vbs >> "mmdsakuk.bat"
echo del sathha.vbs >> "mmdsakuk.bat"
echo start /b "" cmd /c del "%%~f0"^&exit /b >> "mmdsakuk.bat"

REM STARTS THE FILES.
start nmuler.vbs
start sathha.vbs
exit


I never would have even made this post in the first place if I knew someone already did this, I'm not trying to do anything wrong at all, I'm just being made out to look bad. All over me saying that I believe I've successfully encrypted code in batch. Everyone really is over exaggerating because all I was doing is making a simple post about how to take encryption an gradually make it more unreadable.

I have made many of the things I've claimed, by I'm being rushed into everything, the source above would have been better if I had a little more time. This really all had a good intention, I don't care how easily you can decrypt and deobfuscate code, I never said it was hard, I just wanted to post the encryption that took me a while to write.


Just tell me how to delete the post and I will


was going to show ways to encrypt the code even more, but I honestly don't even care anymore.


Possibly Related Threads...
Thread / Author Replies Views Last Post
[Shell] by Robert RougeSep 24, 2026 10:02 AM 4 219 Sep 24, 2026 10:02 AM
Last Post: Anonynuk
[C] by PELockApr 14, 2026 01:15 PM 0 128 Apr 14, 2026 01:15 PM
Last Post: PELock
[Shell] by PELockDec 9, 2024 09:42 AM 3 661 Dec 9, 2024 09:42 AM
Last Post: PELock