BitNinja Part 1: Installation & Setup
BitNinja Server Security — One-Click Installation
BitNinja is a premium Linux server security platform that provides AI-powered malware scanning, WAF, IP reputation, and more. BlitzPress offers one-click deployment — no SSH required.
Important: BitNinja is a paid third-party service ($6-52/server/month). You need your own license key from bitninja.com. A free tier is available for small VPS (≤2 vCPU, ≤2GB RAM, ≤10 hosted users).
BitNinja Feature Set
| Module | What It Does |
|---|---|
| Anti-Malware Suite | AI-powered file scanning with quick scan and deep scan modes |
| Web Application Firewall | Blocks XSS, SQL injection, and other web attacks |
| IP Reputation | 100M+ IP blocklist shared across all BitNinja servers globally |
| AI File Patching | Automatically patches vulnerable files |
| Outbound Spam Detection | Detects and blocks compromised accounts sending spam |
| Site Protection | Per-website security dashboard and monitoring |
| DoS Detection | Detects and mitigates denial-of-service attacks |
| Honeypots | Decoy ports that detect scanning and probing |
| Log Analysis (SenseLog) | Parses web server logs for attack patterns |
| Defense Network | When an IP is blocked on one server, it’s blocked across ALL BitNinja servers |
Prerequisites
- A BitNinja account and license key from bitninja.com
- Server with at least 2GB RAM (BitNinja increases memory usage)
- Debian 11/12/13 or Ubuntu 22.04/24.04
RAM Warning: BitNinja can significantly increase your server’s memory usage (200-500MB). Ensure your server is not already running near capacity before installing.
Getting Your License Key
- Sign up at bitninja.com
- Choose a plan (free tier available for small VPS)
- After login, your license key is displayed on the dashboard
- For additional servers, go to Servers → Add New Server
One-Click Installation via BlitzPress
From the BlitzPress panel:
- Go to your server → Security tab
- Find the BitNinja section
- Paste your license key
- Click “Install BitNinja”
BlitzPress automatically handles everything:
- Installs the BitNinja agent — downloads and provisions with your license key
- Configures SenseLog for OpenLiteSpeed — sets OLS access and error log paths so BitNinja can analyze your web traffic
- Enables automatic updates — adds BitNinja to unattended-upgrades so the agent stays current
- Syncs configs and restarts — ensures all modules are active
- Disables maldet if present — prevents conflicts (BitNinja replaces maldet functionality)
Installation takes 2-3 minutes. A malware scan starts automatically.
Manual Installation (Advanced)
If you prefer to install via SSH:
# SSH into your server
ssh root@your-server-ip
# Install BitNinja
curl -fsSL https://get.bitninja.io/install.sh | /bin/bash -s - --license_key=YOUR_KEY_HERE
# Configure OLS log paths for SenseLog
nano /etc/bitninja/SenseLog/config.ini
Add these log paths (OLS uses Apache sections in BitNinja):
[ApacheAccess]
log_paths[]='/home/*/logs/*access.log'
[ApacheError]
log_paths[]='/home/*/logs/*error.log'
Then sync and reload:
bitninjacli --syncconfigs
bitninjacli --module=SenseLog --reload
service bitninja restart
Enable Automatic Updates
BlitzPress enables this automatically during one-click install. For manual installs:
nano /etc/apt/apt.conf.d/50unattended-upgrades
Add inside the Unattended-Upgrade::Allowed-Origins block:
"bitninja:${distro_codename}";
Then restart:
systemctl restart unattended-upgrades
After Installation
- Dashboard: Manage all BitNinja features at admin.bitninja.io
- Malware scan results are stored in
/var/lib/bitninja - Config files are in
/etc/bitninja/ - Logs are in
/var/log/bitninja/
BitNinja File Locations
| Path | Purpose |
|---|---|
/opt/bitninja/ |
Main installation directory |
/etc/bitninja/ |
Configuration files |
/var/log/bitninja/ |
Log files |
/var/lib/bitninja/ |
Scan results and data |
/usr/sbin/bitninjacli |
CLI management tool |
/opt/bitninja-ssl-termination/ |
SSL termination certs |