Hacktricks Offline
If you are operating in a facility that jams Wi-Fi or disables all wireless protocols (including localhost loopbacks), you need a physical copy. Use wget to recursively mirror the site:
wget --mirror --convert-links --adjust-extension --page-requisites --no-parent https://book.hacktricks.xyz/
Burn this folder to a USB drive or, for the truly paranoid, print the core Linux privilege escalation cheatsheet and laminate it.
The default Hacktricks site has a search bar, but offline static sites often break search. Install ripgrep (rg) on your machine. You can instantly search the entire cloned repository for any command.
cd hacktricks
rg "linpeas"
This is faster than clicking through menus. hacktricks offline
find / -type f -size +10M -mtime -1 2>/dev/null</code></pre>
<h3>Log Analysis</h3>
<pre><code># Auth logs
grep "Failed password" /var/log/auth.log grep "Accepted" /var/log/auth.log
The difference between a junior analyst and a senior penetration tester is often preparation. When the network drops, the junior panics. The senior reaches for their hacktricks offline environment. If you are operating in a facility that
By cloning the repository, building the static site, spinning up a local Docker container, or even just saving a mirrored Wget archive, you ensure that you always have the world’s best cybersecurity encyclopedia at your fingertips.
Don't wait until you are sitting in a cold server room at 2:00 AM with a blinking cursor and no answer. Build your offline copy today. The internet is a luxury; knowledge is essential.
Ready to go dark? Clone the repo, build the site, and never fear the air gap again. Burn this folder to a USB drive or,
I'll help you create a portable, offline HTML document that bundles the most essential HackTricks cheatsheets for pentesting and CTFs. This is a self-contained file you can save and use without internet.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>HackTricks Offline - Pentesting Cheatsheet</title>
<style>
*
margin: 0;
padding: 0;
box-sizing: border-box;
body
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
background: #0a0e17;
color: #c9d1d9;
line-height: 1.6;
.container
display: flex;
max-width: 1400px;
margin: 0 auto;
.sidebar
width: 280px;
background: #0d1117;
height: 100vh;
position: sticky;
top: 0;
overflow-y: auto;
border-right: 1px solid #30363d;
padding: 20px 0;
.sidebar h2
padding: 0 20px 15px;
font-size: 1.2rem;
color: #f0883e;
border-bottom: 1px solid #30363d;
margin-bottom: 15px;
.sidebar ul
list-style: none;
.sidebar li
margin: 5px 0;
.sidebar a
display: block;
padding: 8px 20px;
color: #8b949e;
text-decoration: none;
transition: all 0.2s;
font-size: 0.9rem;
.sidebar a:hover, .sidebar a.active
background: #21262d;
color: #f0883e;
border-left: 3px solid #f0883e;
padding-left: 17px;
.content
flex: 1;
padding: 30px 40px;
overflow-y: auto;
max-height: 100vh;
h1
color: #f0883e;
margin-bottom: 10px;
font-size: 2rem;
.sub
color: #8b949e;
margin-bottom: 30px;
border-bottom: 1px solid #30363d;
padding-bottom: 15px;
h2
color: #79c0ff;
margin: 25px 0 15px 0;
padding-bottom: 5px;
border-bottom: 1px solid #30363d;
h3
color: #d2a8ff;
margin: 20px 0 10px 0;
pre
background: #161b22;
padding: 15px;
border-radius: 6px;
overflow-x: auto;
margin: 15px 0;
border: 1px solid #30363d;
font-size: 0.85rem;
font-family: 'Courier New', monospace;
code
font-family: 'Courier New', monospace;
background: #161b22;
padding: 2px 5px;
border-radius: 4px;
font-size: 0.85rem;
color: #ffa657;
.note
background: #1e2417;
border-left: 4px solid #3fb950;
padding: 12px 15px;
margin: 15px 0;
border-radius: 4px;
.warning
background: #2d1f1f;
border-left: 4px solid #f85149;
padding: 12px 15px;
margin: 15px 0;
border-radius: 4px;
table
width: 100%;
border-collapse: collapse;
margin: 15px 0;
th, td
border: 1px solid #30363d;
padding: 8px 12px;
text-align: left;
th
background: #21262d;
@media (max-width: 800px)
.sidebar display: none;
.content padding: 20px;
</style>
</head>
<body>
<div class="container">
<div class="sidebar">
<h2>📚 HackTricks Offline</h2>
<ul>
<li><a href="#recon" class="active">🔍 Reconnaissance</a></li>
<li><a href="#linux">🐧 Linux Privilege Escalation</a></li>
<li><a href="#windows">🪟 Windows Privilege Escalation</a></li>
<li><a href="#web">🌐 Web Pentesting</a></li>
<li><a href="#reverse">🔄 Reverse Shells</a></li>
<li><a href="#transfer">📁 File Transfer</a></li>
<li><a href="#network">🌍 Network Scanning</a></li>
<li><a href="#password">🔐 Password Attacks</a></li>
<li><a href="#lateral">🕸️ Lateral Movement</a></li>
<li><a href="#forensics">💾 Forensics</a></li>
</ul>
</div>
<div class="content">
<h1>⚡ HackTricks Offline</h1>
<div class="sub">Portable pentesting cheatsheet • No internet required • Updated essential commands</div>
<!-- Reconnaissance -->
<section id="recon">
<h2>🔍 Reconnaissance</h2>
<h3>Nmap Basic Scans</h3>
<pre><code># Quick port scan (top 1000)
nmap -sC -sV -T4 target.com
Offline docs only help if you can find what you need. Here’s my workflow:




