Since Metasploit was removed from the official Termux repositories, installing it has become difficult. This advanced script automates the installation of the latest Metasploit-Framework and specifically fixes the common Nokogiri/Gumbo compilation errors found in newer Ruby versions.
- [+] Automatic Ruby 3.4.0 Gumbo Header Patch.
- [+] Optimized for ARM/ARM64 architectures.
- [+] Silent installation mode (logs errors to
install.log). - [+] Auto-initialization of PostgreSQL Database.
- [+] Stale PID cleanup (Fixes "Could not start server" errors).
- Termux (Latest version from F-Droid)
- Minimum 2GB Internal Storage
- Stable Internet Connection
# Update and upgrade system
apt update && apt upgrade -y
# Install git
apt install git -y
# Clone the repository
git clone [https://github.com/h4ck3r0/Metasploit-termux](https://github.com/h4ck3r0/Metasploit-termux)
# Enter directory
cd Metasploit-termux
# Grant execution permission
chmod +x *
# Run the installer
bash metasploit.shAfter successful installation, simply type:
msfconsole
For payload generation:
msfvenom
Metasploit is resource-intensive. If the process is killed by Android, ensure you have disabled "Battery Optimization" for Termux.
Developed by Raj Aryan (h4ck3r0) Give a ⭐ if this script helped you!
- Modern Badges: Updated the styling of badges and added a specific badge for Ruby 3.4.0 compatibility.
- Detailed Features: Highlighted the "Nokogiri Gumbo Fix" and "Stale PID Cleanup" which are the unique selling points of your updated script.
- Clean Installation Commands: Removed unnecessary steps (like installing Python 2) because our new main script handles all dependencies automatically.
- Social Links: Re-organized social links for better visibility.
- Technical Accuracy: Fixed the height/width typo in the image tag and improved the overall Markdown structure.

