Skip to content
ADscan Docs

🛠️ Installation

Install the ADscan launcher with pipx/pip and pull the Docker runtime image.

ADscan is installed as a small launcher (pipx / pip) that runs ADscan inside Docker by default.

Current version: ADscan version 11.0.0-lite

  • Linux (x86_64/amd64 or arm64/aarch64), or macOS with Docker Desktop
  • Docker Engine (docker)
  • Permission to run Docker (root or in the docker group)
  • 15 GB free disk on the Docker storage path. Two sizes differ: the image is about 4.8 GB to download (compressed layers), and about 12 GB on disk once Docker unpacks it. Budget for the on-disk size plus your workspaces and logs; the launcher refuses to pull below 15 GB and leaves the rest as headroom for an in-place upgrade
  • Internet access (pulls the ADscan container image)
  • Supported runtime: Docker Engine (Podman Docker API is opt-in advanced mode)

Why Docker-first?

Docker mode avoids the biggest source of installation failures: dependency drift across distributions. It also keeps tooling isolated and makes upgrades much simpler.

Platform support

Launcher runtime commands (install, check, start, ci, update, upgrade) run on Linux and on macOS with Docker Desktop. Everything else fails fast with a clear platform message. Both x86_64/amd64 and arm64/aarch64 are supported. Runtime images are published as a multi-arch manifest, so docker pull selects the right build automatically, Apple Silicon included. On macOS, containers run inside Docker Desktop's Linux VM. Routed scanning over NAT works normally (LDAP, Kerberos, SMB against a reachable target), but broadcast poisoning (LLMNR, NBT-NS, mDNS) needs Layer-2 access to your local network and is not available. Use a Linux host or Linux VM if you need it. Windows uses a different, Docker-free path: a self-contained bundle that runs adscan.exe directly (no launcher, no Docker, no Python). See Native Windows below. WSL and WSL2 are still blocked by default under the Docker launcher; on Windows use the native bundle rather than WSL. On arm64, hashcat and donut are not bundled (John the Ripper handles cracking natively); use an amd64 host if you rely on those two tools.

Step 1 — Install the ADscan launcher

pipx ensures ADscan runs in an isolated environment without affecting your system Python.

bash
# Install pipx if not already installed
sudo apt update
sudo apt install -y pipx
pipx ensurepath

# Install ADscan
pipx install adscan

Method 2: Install with pip

bash
pip install adscan

Verify Installation

ADscan is designed to run as a normal user. It will request sudo only for the specific steps that need it.

bash
adscan --version

Step 2 — Install Docker

If you already have Docker, verify it:

bash
docker version

Note: ADscan 9.x no longer requires docker compose. The previous BloodHound CE container stack was replaced by the native attack-path collector, so the launcher only needs the Docker Engine.

bash
sudo apt update
sudo apt install -y docker.io
sudo systemctl enable --now docker

Install Docker Engine from Docker's official apt repository:

bash
# Remove distro Docker packages that can conflict with docker-ce
sudo apt remove -y docker.io docker-compose docker-doc podman-docker containerd runc || true

# Add Docker's apt repository
sudo apt update
sudo apt install -y ca-certificates curl
sudo install -m 0755 -d /etc/apt/keyrings

# Ubuntu hosts
if [ "$( . /etc/os-release && echo "$ID" )" = "ubuntu" ]; then
  sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc
  sudo chmod a+r /etc/apt/keyrings/docker.asc
  echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/ubuntu $(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \
    sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
else
  # Debian hosts
  sudo curl -fsSL https://download.docker.com/linux/debian/gpg -o /etc/apt/keyrings/docker.asc
  sudo chmod a+r /etc/apt/keyrings/docker.asc
  echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/debian $(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \
    sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
fi

sudo apt update
sudo apt install -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin
sudo systemctl enable --now docker

Use distro packages for simplicity/compatibility:

bash
sudo apt update
sudo apt install -y docker.io
sudo systemctl enable --now docker

Convenience script (quick setup)

get.docker.com is useful for fast development bootstrap, but for long-term reproducibility use package-repository installs.

bash
curl -fsSL https://get.docker.com/ -o get-docker.sh
sudo sh ./get-docker.sh

Allow your user to run Docker without sudo (recommended):

bash
sudo usermod -aG docker "$USER"
# Log out/in, or run:
newgrp docker

Step 3 — Pull the ADscan image

bash
adscan install

Slow networks / VPN pulls

If your docker pull takes a long time (large images), consider installing on a faster connection (VPNs/proxies can throttle Docker pulls).

You can also increase the pull timeout:

bash
adscan install --pull-timeout 3600

To disable the pull timeout entirely:

bash
adscan install --pull-timeout 0

What this does (Docker mode):

  • Pulls the ADscan image (adscan/adscan-lite:latest)
  • Verifies Docker Engine is reachable and the user has permission to run containers
  • Prepares the workspace directory under ~/.adscan/

That's it — no additional services, no compose stack, no BloodHound container to manage. Attack-path analysis runs inside the ADscan container using the native graph collector. If you want a BloodHound UI to explore graphs visually, you can run your own BloodHound CE instance separately and load the exported attack_graph.json.

Podman environments

ADscan is validated against Docker Engine by default. If your DOCKER_HOST points to a Podman socket, launcher commands will fail fast unless you explicitly opt in:

bash
export ADSCAN_ALLOW_PODMAN_DOCKER_API=1

Use this only if your Podman Docker API setup is intentional and stable.

Step 4 — Start ADscan

bash
adscan start

Run as normal user

Run ADscan launcher as your normal user (recommended):

bash
adscan install
adscan start

Avoid running from a root shell (sudo su / su -) because it can create state under /root/.adscan and cause permission/context issues.

Do not launch ADscan from inside the runtime container

ADscan FULL runtime must be started by the official host launcher installed with pipx install adscan or pip install adscan.

Do not docker exec into the container and run adscan manually from there. The launcher prepares required runtime wiring before startup, including:

  • host-helper socket access
  • local DNS resolver context
  • workspace/state mounts
  • launcher/runtime environment markers

If you open a shell inside the container and run adscan directly, ADscan now blocks startup on purpose and tells you to exit the container and launch it again from the host.

One Docker runtime session at a time

ADscan currently supports one active Docker runtime session per ADSCAN_HOME.

Do not launch adscan start, adscan ci, adscan check, or another launcher-driven Docker command from a second terminal while an ADscan runtime is already active.

Why this is blocked:

  • the host-helper socket is shared
  • runtime run/, state/, and logs/ mounts are shared
  • workspace persistence paths are shared

If you try to start a second session, ADscan now stops early and shows which launcher command is already active. Return to that terminal, exit the active ADscan session cleanly, then retry.

On start, ADscan will:

  • Run the ADscan container with host networking
  • Mount persistent directories from ~/.adscan/:
    • workspaces/
    • logs/
    • run/
    • state/
    • .config/ (used by local CLI integrations like Codex auth)

The launcher also injects runtime-only context that the container needs for premium workflows such as GUI host file picking, host clock sync, and AD-managed DNS forwarding. This is why the supported way to run ADscan is always:

bash
adscan start

from the host terminal, not from an interactive shell inside the container.

Memory

How much memory a scan needs depends on the directory. The number of objects matters less than how densely they are connected. Attack-path discovery and the reports work on relationships (group memberships, permissions, sessions), so a small directory where a few groups control almost everything can need more than a large, tidy one.

What you are assessingMemory to give ADscan
Labs, CTF boxes and small domains4 GB, the minimum
A real client domain8 GB
A large directory, or one with very broad permissions16 GB

Two measurements on test directories we generate show the scale. Take them as guidance, since no two directories are alike. A directory of about 58,000 objects and 900,000 relationships completed with a peak near 4.5 GB. A directory ten times that size, given 8 GB, did not fit, and the run ended with a declared stop instead of a crash.

The figure that counts is the memory ADscan can use where it runs. That is the container's memory limit when one is set, the amount a virtual machine was given, and what other programs on the machine leave free.

Before the scan starts

adscan install, adscan start, adscan check and adscan ci look at the memory available before they start the container.

  • Under 1 GB available. ADscan does not start. An unattended run fails at once and an interactive run asks you to confirm. 1 GB is the supported minimum, because below it a stage that grows quickly can run out of memory before ADscan is able to stop it cleanly.
  • Between 1 GB and 1.5 GB. A warning, and the run goes on.
  • 1.5 GB or more. No warning.

To go ahead on purpose on a constrained machine, pass --allow-low-memory.

bash
adscan start --allow-low-memory
adscan ci --allow-low-memory -- <ci-args>

This check looks at the machine once, before the scan. It cannot see what a large directory will need an hour later, which is what the next part is for.

When a stage runs short of memory

From 15.0.0 every heavy stage of a scan watches memory while it works. That covers directory collection, building the relationship graph, attack-path discovery, the choke-point analysis and report rendering. A stage stops itself before the operating system would kill the scan, keeps what it finished, and tells you what to do with real figures.

shell
╭─ » Not enough memory to finish attack-path discovery ────────────────────────╮
│                                                                              │
│  Attack-path discovery stopped at about 3,400 MB of memory, 85% of the       │
│  4,000 MB it can use, before the system would kill it.                       │
│  Kept: 12,400 routes already examined. The rest is reported as not           │
│  evaluated, so nothing is hidden.                                            │
│  This computation needs about 6.5 GB to finish.                              │
│                                                                              │
│  To finish it, give ADscan more memory:                                      │
│    • This container has a memory limit. Raise it (for Docker, run with a     │
│      larger --memory) and re-run.                                            │
│                                                                              │
│  Then reopen this workspace and choose Resume to finish attack-path          │
│  discovery.                                                                  │
│                                                                              │
╰──────────────────────────────────────────────────────────────────────────────╯

The panel names the stage that stopped and what was kept, how much memory it had, and roughly how much the computation needs when ADscan could estimate it. The ways to give it more memory are the ones that apply where it is running. ADscan detects a container memory limit, the WSL memory cap, a machine whose own memory is the limit, and other programs competing for memory, and lists only what it found.

Nothing collected is lost. Give the machine more memory, open the workspace again with adscan start and choose Resume. Only the stage that stopped runs again. The end-of-scan summary repeats that step, so a panel that scrolled away is not lost.

On a very large directory ADscan may say, before attack-path discovery starts, that the full computation will not fit.

shell
This directory is large: with the 4,000 MB available, ADscan will examine a representative sample of routes; give it about 9 GB for the full set.

The scan then goes on with a declared sample of routes. With the memory it names, a resumed run computes the full set.

A stop for memory is never reported as a clean result. The report and the Enterprise platform state which part was not evaluated, and adscan ci ends with exit code 3, the incomplete-assessment status. The message is about memory on the machine that ran the scan. It says nothing about the state of the directory.

See Troubleshooting if a run was killed by the system outright.

Docker is the only install mode on Linux and macOS

Older releases shipped a host-based installer that provisioned apt, Python, Go and Rust dependencies directly on your machine. It is gone. On Linux and macOS, Docker is now the only supported way to run ADscan, and there is no flag that restores the old path. If Docker is not allowed on the machine you work from, either run ADscan on a Linux VM that permits it, or use the native Windows bundle below.

Native Windows

On Windows, ADscan does not use Docker or the launcher at all. It ships as a self-contained bundle that runs adscan.exe directly: the engine, its Python runtime, the native Active Directory stack, and the bundled tools all travel inside the bundle. Nothing is installed on the host.

This is built for the assumed-breach reality where your only foothold is a domain-joined Windows workstation that you cannot modify:

  • No Docker, no Python, no local admin. It runs as a normal domain user.
  • Offline-first. The bundle carries its own wordlists and tools, so it works on a locked-down host with no internet egress.
  • Same engine as Linux. The scan, the attack-path analysis, and the client report are identical; only the packaging differs.
  • Password cracking on CPU. A hardened host usually has no GPU compute stack, so cracking falls back to a CPU cracker automatically — no GPU or driver required.
  • In-process port scan. No Npcap driver or admin rights are needed; the scan is paced conservatively by default so it stays gentle on monitored networks.

To use it, download adscan.exe from the latest GitHub release. It is a single file of several hundred MB. Windows marks downloaded files as coming from the internet, so unblock it once (right-click, Properties, Unblock, or Unblock-File .\adscan.exe in PowerShell). Then check the version and start the interactive shell.

powershell
.\adscan.exe --version
.\adscan.exe start

The unattended commands (ci and execute) are part of PRO.

Interactive mode (adscan.exe start) works the same as on Linux.

Important: Remove legacy sudo alias (if present)

Older versions used to add a shell alias that forced running every command as sudo -E. This is no longer required and can cause permission issues (for example, a root-owned ~/.adscan directory).

If you previously used a legacy alias, remove the block from your shell config (~/.zshrc, ~/.bashrc, or ~/.bash_aliases) and repair ownership:

bash
# Remove the legacy alias block (look for "# ADscan auto-sudo alias")
# Then fix ownership if needed:
sudo chown -R "$USER":"$USER" ~/.adscan

Next Steps

Once installation is complete, proceed to the Quick Start guide to run your first scan.

Troubleshooting

If you run into issues, see the Troubleshooting guide. For Docker-mode startup blockers, use the Host helper troubleshooting section.

Find this useful?
Pass it to the next pentester running an AD engagement
Running 2+ AD engagements/year?
First PRO assessment free·Free in exchange for feedback
Automated PDF reports. Save ≥1 day per engagement.

ADscan — AD pentest automation for security consultants