Last active
September 1, 2021 09:25
-
-
Save richardcurteis/905f85fa801862181fe924a1c0ea9f50 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| if [[ $# -eq 0 ]];then | |
| echo "[!] Email must be provided for Git SSH key" | |
| exit 1 | |
| fi | |
| sudo passwd kali | |
| USER=`whoami` | |
| EMAIL=$1 | |
| sudo apt-get update && sudo apt-get upgrade -y | |
| sudo apt autoremove -y | |
| ssh-keygen -t ed25519 -C $EMAIL | |
| eval "$(ssh-agent -s)" | |
| ssh-add ~/.ssh/id_ed25519 | |
| cat ~/.ssh/id_ed25519.pub | |
| read -p "Copy pubkey to git... " | |
| # apt repos | |
| sudo apt-get install -y libssl-dev libffi-dev python-dev build-essential | |
| sudo apt install -y curl | |
| sudo apt install -y git | |
| sudo apt install -y wget | |
| sudo wget https://repo1.maven.org/maven2/org/python/jython-standalone/2.7.2/jython-standalone-2.7.2.jar | |
| sudo mv jython-standalone-2.7.2.jar /opt/jython-standalone-2.7.2.jar | |
| sudo apt install -y tmux | |
| sudo apt install -y rlwrap | |
| sudo apt install -y netcat ncat | |
| sudo apt install -y python3-pip | |
| sudo apt install -y flameshot | |
| sudo apt install -y zip | |
| sudo apt install -y virtualenv | |
| sudo apt install -y jq | |
| sudo apt install -y telnet | |
| sudo apt install -y npm | |
| sudo apt install -y nmap | |
| sudo apt install -y dns-utils | |
| sudo apt install -y net-tools | |
| sudo apt install -y zsh | |
| sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" | |
| # NPM | |
| sudo npm install g node | |
| # Install Go | |
| wget https://golang.org/dl/go1.16.7.linux-amd64.tar.gz | |
| sudo rm -rf /usr/local/go && sudo tar -C /usr/local -xzf go1.16.7.linux-amd64.tar.gz | |
| export PATH=$PATH:/usr/local/go/bin | |
| # Metasploit | |
| sudo service postgresql start | |
| sudo msfdb init | |
| # TMUX conf | |
| curl https://gist.github.com/prachauthit/595cd3596267b303cc77fe0409c33530/raw/9de5070df1fb1adfc2f6db2b4966c516ec931700/ippsec-tmux -o ~/.tmux.conf | |
| # Python3 HTTP server | |
| curl https://gist.github.com/richardcurteis/66777e446d23ca3b4bfc622f85b7a2d7/raw/28b7e048eab3b392dddff605250384a5a9917546/python-https-simple-server.py -o simple-https-server.py | |
| mkdir SimpleHTTPSServer | |
| openssl req -new -x509 -keyout server.pem -out server.pem -days 365 -nodes | |
| mv simple-https-server.py SimpleHTTPSServer/simple-https-server.py | |
| mv server.pem SimpleHTTPSServer/server.pem | |
| # VSCode | |
| wget https://code.visualstudio.com/sha/download?build=stable&os=linux-deb-x64 | |
| sudo dpkg -i ./code_1.59.0-1628120042_amd64.deb | |
| rm code_1.59.0-1628120042_amd64.deb | |
| # Cherry Tree | |
| wget https://launchpad.net/~giuspen/+archive/ubuntu/ppa/+build/21797903/+files/cherrytree_0.99.39-4_amd64.deb | |
| sudo dpkg -i ./cherrytree_0.99.39-4_amd64.deb | |
| rm cherrytree_0.99.39-4_amd64.deb | |
| # Jython | |
| wget https://repo1.maven.org/maven2/org/python/jython-standalone/2.7.2/jython-standalone-2.7.2.jar | |
| sudo mv jython-standalone-2.7.2.jar /opt/jython-standalone-2.7.2.jar | |
| # Git repo setups | |
| mkdir ~/repos | |
| cd ~/repos | |
| git clone [email protected]:pwntester/ysoserial.net.git | |
| git clone [email protected]:frohoff/ysoserial.git | |
| git clone [email protected]:danielmiessler/SecLists.git | |
| git clone [email protected]:SecureAuthCorp/impacket.git | |
| git clone [email protected]:swisskyrepo/PayloadsAllTheThings.git | |
| git clone [email protected]:GrrrDog/Java-Deserialization-Cheat-Sheet.git | |
| git clone [email protected]:Realize-Security/MaliciousWordpressWebshell.git | |
| git clone [email protected]:richardcurteis/TLS_SSL_Checks_sh.git | |
| git clone [email protected]:richardcurteis/password_spraying.git | |
| git clone [email protected]:richardcurteis/goBrute.git | |
| git clone --recursive https://github.com/byt3bl33d3r/CrackMapExec | |
| cd CrackMapExec | |
| poetry install | |
| cd ../../ | |
| # Rockyou | |
| cp /usr/share/wordlists/rockyou.gz . | |
| gunzip gunzip rockyou.gz/rockyou.gz | |
| rm rockyou.gz | |
| mv /usr/share/wordlists/rockyou.txt ~/repos | |
| # Ffuf | |
| wget https://github.com/ffuf/ffuf/releases/download/v1.3.1/ffuf_1.3.1_linux_amd64.tar.gz | |
| gunzip ffuf_1.3.1_linux_amd64.tar.gz | |
| tar xvf ffuf_1.3.1_linux_amd64.tar | |
| mv ffuf_1.3.1_linux_amd64/ffuf /opt/ffuf | |
| rm ffuf_1.3.1_linux_amd64.tar | |
| sudo ln -s /opt/ffuf /usr/bin/ffuf | |
| # Aquatone | |
| wget https://github.com/michenriksen/aquatone/releases/download/v1.7.0/aquatone_linux_amd64_1.7.0.zip | |
| unzip aquatone_linux_amd64_1.7.0.zip | |
| sudo mv aquatone_linux_amd64_1.7.0/aquatone /opt/aquatone | |
| sudo ln -s /opt/aquatone /usr/bin/aquatone | |
| # Dotnet | |
| sudo apt-get update; \ | |
| sudo apt-get install -y apt-transport-https && \ | |
| sudo apt-get update -y && \ | |
| sudo apt-get install -y dotnet-sdk-5.0 | |
| # | |
| # Clean up | |
| rm LICENSE* README.md aquatone aquatone_linux_amd64_1.7.0.zip ffuf_1.3.1_linux_amd64.tar ffuf | |
| # pip installs | |
| pip3 install requests | |
| pip3 install flask | |
| # Docker | |
| sudo apt-get remove -y docker docker-engine docker.io containerd runc | |
| sudo apt-get update | |
| sudo apt-get install -y \ | |
| apt-transport-https \ | |
| ca-certificates \ | |
| curl \ | |
| gnupg \ | |
| lsb-release | |
| curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg | |
| echo \ | |
| "deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu \ | |
| $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/nul | |
| sudo apt-get update | |
| sudo apt-get -y install docker-ce docker-ce-cli containerd.io | |
| sudo curl -L "https://github.com/docker/compose/releases/download/1.29.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose | |
| sudo chmod +x /usr/local/bin/docker-compose | |
| sudo usermod -a -G docker $USER | |
| # | |
| USER=`whoami` | |
| sudo chown -R $USER:$USER . | |
| sudo apt autoremove -y |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment