Skip to content

Instantly share code, notes, and snippets.

@songwutk
Created December 15, 2025 05:03
Show Gist options
  • Select an option

  • Save songwutk/d2be4225fbd79e164def050b2f21ba73 to your computer and use it in GitHub Desktop.

Select an option

Save songwutk/d2be4225fbd79e164def050b2f21ba73 to your computer and use it in GitHub Desktop.
#!/bin/bash
# สีสำหรับ Output
GREEN='\033[0;32m'
YELLOW='\033[1;33m'
BLUE='\033[0;34m'
NC='\033[0m' # No Color
echo -e "${BLUE}======================================================${NC}"
echo -e "${BLUE} Google Cloud Pentest Setup (Native/No-Docker) ${NC}"
echo -e "${BLUE}======================================================${NC}"
# 1. Update System
echo -e "${YELLOW}[+] Updating & Upgrading System...${NC}"
sudo apt update && sudo apt upgrade -y
# 2. Install Essential Utilities (ตามที่คุณขอ + ตัวจำเป็น)
echo -e "${YELLOW}[+] Installing System Utilities (htop, screen, netstat, etc.)...${NC}"
sudo apt install -y \
htop \
screen \
tmux \
net-tools \
whois \
netcat-traditional \
socat \
curl \
wget \
git \
vim \
nano \
p7zip-full \
build-essential \
libssl-dev \
libffi-dev \
zlib1g-dev \
dnsutils \
iputils-ping
# 3. Language Environments (Python, Ruby, Perl, Go)
echo -e "${YELLOW}[+] Setting up Language Environments...${NC}"
# Python
sudo apt install -y python3-dev python3-pip python3-venv pipx
# Ruby (for WPScan)
sudo apt install -y ruby-dev
# Perl (for JoomScan/Nikto) & Libs
sudo apt install -y perl libwww-perl libxml2 libxml2-dev libxslt1-dev
ensurepath # update pipx path
# 4. Install Exploit Database (MUST HAVE for CMSMap & Searchsploit)
echo -e "${YELLOW}[+] Installing ExploitDB (Resolves CMSMap errors)...${NC}"
if [ ! -d "/usr/share/exploitdb" ]; then
sudo git clone https://github.com/offensive-security/exploitdb.git /usr/share/exploitdb
# Link command 'searchsploit' to bin
sudo ln -sf /usr/share/exploitdb/searchsploit /usr/local/bin/searchsploit
else
echo -e "${GREEN}ExploitDB already installed.${NC}"
fi
# 5. Core Pentest Tools (APT)
echo -e "${YELLOW}[+] Installing Core Tools (Nmap, Hydra, Sqlmap, Gobuster)...${NC}"
sudo apt install -y nmap sqlmap hydra gobuster nikto seclists
# 6. Metasploit Framework
echo -e "${YELLOW}[+] Installing Metasploit Framework...${NC}"
curl https://raw.githubusercontent.com/rapid7/metasploit-omnibus/master/config/templates/metasploit-framework-wrappers/msfupdate.erb > msfinstall
chmod 755 msfinstall
sudo ./msfinstall
rm msfinstall
# 7. Setup Directory Structure
mkdir -p ~/pentest-tools
mkdir -p ~/wordlists
# Link SecLists to home for easy access
if [ -d "/usr/share/seclists" ]; then
ln -sf /usr/share/seclists ~/wordlists/SecLists
fi
echo -e "${GREEN}======================================================${NC}"
echo -e "${GREEN} SETUP COMPLETE! (Native Mode) ${NC}"
echo -e "${GREEN}======================================================${NC}"
echo -e "คำแนะนำ:"
echo -e "1. พิมพ์ 'source ~/.bashrc' เพื่อโหลด Alias ใหม่"
echo -e "2. เรียกใช้เครื่องมือได้เลย:"
echo -e " - ${BLUE}searchsploit${NC} joomla 3.9"
echo -e " - ${BLUE}htop${NC} / ${BLUE}screen${NC} / ${BLUE}netstat -tulnp${NC}"
echo -e "--------------------------------------------------------"
@songwutk
Copy link
Author

6GB Remain 4GB

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment