Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #! /usr/bin/env bash
- # Color Codes of Regular Colors
- Black='\033[0;30m' # Black
- Red='\033[0;31m' # Red
- Green='\033[0;32m' # Green
- Yellow='\033[0;33m' # Yellow
- Blue='\033[0;34m' # Blue
- Purple='\033[0;35m' # Purple
- Cyan='\033[0;36m' # Cyan
- White='\033[0;37m' # White
- Nc='\033[0m' # No Color
- # banner
- clear
- printf "\n\n${Green}Hacking Tools and Wordlist Installer written by,\n\n\n"
- printf "${Red}" # banner bg and fg color
- cat << "EOF"
- _____ _ _ _ _____ _ _
- |_ (_)__| |_ __ _ _ _ /_\ __| |_ _| |_ __ _ _ _ __| |__ _ _ _
- / /| (_-| ' \/ _` | ' \ / _ \/ _` | | | | ' \/ _` | ' \/ _` / _` | '_|
- /___|_/__|_||_\__,_|_||_/_/ \_\__,_| |_| |_||_\__,_|_||_\__,_\__,_|_|
- EOF
- printf "\n\n${Cyan}https://twitter.com/ZishanAdThandar${Nc}\n\n"
- sleep 2 #banner break
- # one liner bash if loop to check root user
- [ "$EUID" -ne 0 ] && printf "\n\033[30;5;41mPlease run as root.${Nc}\n" && sudo su
- # function for wordlists from github
- function wsgit {
- [ -d "/opt/wordlist/$1" ] && printf "${Green}$1 already installed${Nc}\n"
- [ ! -d "/opt/wordlist/$1" ] && git clone $2 /opt/wordlist/$1 && printf "${Purple}$1 downloaded successfully\n${Nc}"
- }
- # function for wordlists with wget
- function wswget {
- [ -f "/opt/wordlist/$1" ] && printf "${Green}$1 already downloaded${Nc}\n"
- [ ! -f "/opt/wordlist/$1" ] && wget $2 -O /opt/wordlist/$1 && printf "${Purple}$1 downloaded\n${Nc}"
- }
- # Making wordlist folder if not exist
- [ ! -d "/opt/wordlist" ] && mkdir /opt/wordlist
- cd /opt/wordlist
- printf "we are in $(pwd) folder.\n\n/opt/wordlist/ Folder Contains:\n"
- ls
- # Array for wordlists
- declare -A wsgitarray=( [PayloadsAllTheThings]="https://github.com/swisskyrepo/PayloadsAllTheThings" [SecLists]="https://github.com/danielmiessler/SecLists" [fuzzdb]="https://github.com/fuzzdb-project/fuzzdb" [node-dirbuster]="https://github.com/daviddias/node-dirbuster" [api_wordlist]="https://github.com/chrislockard/api_wordlist")
- declare -A wsgetarray=( [all.txt]="https://gist.githubusercontent.com/jhaddix/86a06c5dc309d08580a018c66354a056/raw/96f4e51d96b2203f19f6381c8c545b278eaa0837/all.txt" [markdownxss.txt]="https://raw.githubusercontent.com/cujanovic/Markdown-XSS-Payloads/master/Markdown-XSS-Payloads.txt")
- # for loop to git clone wordlists
- for i in "${!wsgitarray[@]}"
- do
- wsgit $i ${wsgitarray[$i]}
- done
- # for loop to wget wordlists
- for i in "${!wsgetarray[@]}"
- do
- wswget $i ${wsgetarray[$i]}
- done
- # Rockyou unzipping
- [ -f "/opt/wordlist/rockyou.txt" ] && printf "${Green}rockyou.txt already downloaded${Nc}\n"
- [ ! -f "/opt/wordlist/rockyou.txt" ] && tar -xf /opt/wordlist/SecLists/Passwords/Leaked-Databases/rockyou.txt.tar.gz -C /opt/wordlist/ && printf "${Purple}unzipped rockyou.txt${Nc}\n"
- # Assetnote API wordlist (creates logical block error, because of large files)
- # [ -d "/opt/wordlist/assetnote" ] && printf "\n${Yellow}Assetnote API wordlist already installed${Nc}\n"
- #[ ! -d "/opt/wordlist/assetnote" ] && mkdir /opt/wordlist/assetnote && wget -r --no-parent -R "index.html*" https://wordlists-cdn.assetnote.io/data/ -nH -np /opt/wordlist/assetnote/ && printf "${Purple}Assetnote API wordlist downloaded successfully\n${Nc}" && mv /opt/wordlist/data/* /opt/wordlist/assetnote && rm -rf /opt/wordlist/data
- printf "\n${Cyan}Stage 1 Finished!\nWordlists Downloaded.${Nc}\n\n"
- sleep 3 #stage 1 break
- declare -a aptarray=("aircrack-ng" "audacity" "axiom" "beef" "binwalk" "bully" "cewl" "crunch" "dirb" "dnsenum" "dnsrecon" "exiftool" "ffmpeg" "git" "hashcat" "hcxdumptool" "httrack" "hydra" "john" "jq" "libpcap-dev" "masscan" "macchanger" "ndiff" "nodejs" "nikto" "nmap" "npm" "openvpn" "pixiewps" "pngcheck" "proxychains" "python2" "python3" "python3-pip" "reaver" "stegcracker" "steghide" "tmux" "tor" "uget" "wafw00f" "wapiti" "whatweb" "wifite" "wireshark" "youtube-dl")
- ### NOTE: "python3-pip" "libpcap-dev" "uget" will be installed but not showing because command is different.
- #Function to check if installed and install it
- function aptinstall {
- dpkg -l "$1" | grep -q ^ii && return 1
- apt-get -y install "$1"
- return 0
- }
- #Installing from array
- for i in "${aptarray[@]}"
- do
- aptinstall $i
- done
- #functions to check missing tools
- function missapt {
- if ! command -v $1 &> /dev/null
- then
- printf "${Red}Install $1 manually.\n${Nc}"
- fi
- }
- #Recommending missing tools from array
- for i in "${aptarray[@]}"
- do
- missapt $i
- done
- printf "\n${Cyan}Stage 2 Finished!\nApt Installation Finished.\nCheck for missing tools and manually install.${Nc}\n"
- sleep 2 #stage 2 break
- # installing and setting up Golang
- [ -d "/usr/local/go" ] && printf "\n${Green}GoLang already downloaded${Nc}\n"
- [ ! -d "/usr/local/go" ] && cd /tmp && wget https://go.dev/dl/go1.20.1.linux-amd64.tar.gz && tar -C /usr/local/ -xzf go1.20.1.linux-amd64.tar.gz && cd /usr/local/ && printf "export GOROOT=/usr/lib/go \nexport GOPATH=\$HOME/go \nexport PATH=\$PATH:$GOROOT/bin:\$GOPATH/bin" >> ~/.bashrc && printf "export GOROOT=/usr/lib/go \nexport GOPATH=\$HOME/go \nexport PATH=\$PATH:$GOROOT/bin:\$GOPATH/bin" >> /home/*/.bashrc && source ~/.bashrc && source /home/*/.bashrc
- # Installing GoLang tools
- printf "\n${Cyan}Installing Go Tools for user ${Red}ROOT${Nc}${Cyan} (Current User).${Nc}\n\n"
- sleep 1
- function goinstall {
- [ -f "$HOME/go/bin/$1" ] && printf "${Green}$1 already installed.\n${Nc}"
- [ ! -f "$HOME/go/bin/$1" ] && go install -v $2 && printf "$1 installed successfully.\n"
- }
- declare -A goinstallarray=( [amass]="github.com/OWASP/Amass/v3/...@master" [assetfinder]="github.com/tomnomnom/assetfinder@latest" [dalfox]="github.com/hahwul/dalfox@latest" [ffuf]="github.com/ffuf/ffuf@latest" [gf]="github.com/tomnomnom/gf@latest" [git-hound]="github.com/tillson/git-hound@latest" [gobuster]="github.com/OJ/gobuster/v3@latest" [hakrawler]="github.com/hakluke/hakrawler@latest" [httprobe]="github.com/tomnomnom/httprobe@master" [httpx]="github.com/projectdiscovery/httpx/cmd/httpx@latest" [interactsh-client]="github.com/projectdiscovery/interactsh/cmd/interactsh-client@latest" [naabu]="github.com/projectdiscovery/naabu/v2/cmd/naabu@latest" [nuclei]="github.com/projectdiscovery/nuclei/v2/cmd/nuclei@latest" [qsreplace]="github.com/tomnomnom/qsreplace@latest" [waybackurls]="github.com/tomnomnom/waybackurls@latest" [subfinder]="github.com/projectdiscovery/subfinder/v2/cmd/subfinder@latest" [subzy]="github.com/LukaSikic/subzy@latest")
- for i in "${!goinstallarray[@]}"
- do
- goinstall $i ${goinstallarray[$i]}
- done
- # setting gf patterns by 1ndianl33t
- [ -d "$HOME/.gf" ] && printf "${Green}gf patterns by 1ndianl33t already installed.\n${Nc}"
- [ ! -d "$HOME/.gf" ] && git clone https://github.com/1ndianl33t/Gf-Patterns ~/.gf && printf "gf patterns by 1ndianl33t installed succesfully.\n"
- [ -f "$HOME/.gf/base64.json" ] && printf "${Green}gf patterns by tomnomnom already installed.\n${Nc}"
- [ ! -f "$HOME/.gf/base64.json" ] && git clone https://github.com/tomnomnom/gf /tmp/gf && mv /tmp/gf/examples/* ~/.gf/ && printf "gf patterns by tomnomnom installed succesfully.\n"
- #At the end Installing python3 tools
- printf "\n${Cyan}Installing Python Tools for user ROOT.${Nc}\n"
- sleep 1
- yes | python3 -m pip install -U pip --quiet #update pip
- yes | python3 -m pip install sublist3r dirsearch pwntools arsenal-cli --quiet
- yes | python3 -m pip install sublist3r dirsearch pwntools arsenal-cli sqlmap --quiet
- # Ruby Based Tools
- # WPScan Installation
- [ ! -f "/usr/local/bin/wpscan" ] && sudo apt install curl git libcurl4-openssl-dev make zlib1g-dev gawk g++ gcc libreadline6-dev libssl-dev libyaml-dev libsqlite3-dev sqlite3 autoconf libgdbm-dev libncurses5-dev automake libtool bison pkg-config ruby ruby-bundler ruby-dev -y && sudo gem install wpscan
- # metasploit installation
- if ! command -v msfconsole &> /dev/null
- then
- curl -s https://raw.githubusercontent.com/rapid7/metasploit-omnibus/master/config/templates/metasploit-framework-wrappers/msfupdate.erb > msfinstall && \
- chmod 755 msfinstall && \
- ./msfinstall
- rm msfinstall
- fi
- printf "\n${Cyan}Stage 3 Finished!\nOne by One Installation Finished.\nRun this script 4-5 times ${Red}WITH REOPENING TERMINAL AS ROOT. \n${Cyan}Check for missing tools in output and manually install.${Nc}\n\n"
- printf "${Green}Thank you for using.\nHackify by ZɪsʜᴀɴAᴅTʜᴀɴᴅᴀʀ\n\n${nc}"
Add Comment
Please, Sign In to add comment