Skip to content

NoPAC Check

Tests each discovered Domain Controller for the NoPAC vulnerability chain (CVE-2021-42278 and CVE-2021-42287) by comparing PAC and non-PAC TGT responses.

ad-kit check nopac

Prerequisite

Requires a valid Standard User account (authenticated).

Commands run

ad-kit runs NetExec against each Domain Controller:

nxc smb <dc_ip> -u <username> -p <password> -M nopac

What it checks

ad-kit compares the size of a TGT returned with a Privilege Attribute Certificate (PAC) against one returned without it. A "without PAC" TGT smaller than the "with PAC" TGT indicates the controller is vulnerable.

How it works

NoPAC chains two issues:

  • CVE-2021-42278 is sAMAccountName spoofing: an account can be renamed to match a Domain Controller (minus the trailing $).
  • CVE-2021-42287 is a KDC lookup flaw: requesting a service ticket for a nonexistent account causes the KDC to append $ and resolve the matching machine account, mis-associating the ticket.

The PAC carries the user's security information (SID, groups, rights). A controller that returns a TGT without a PAC can be induced to issue tickets that bypass normal PAC validation, enabling the S4U2Self flow to impersonate a privileged user such as Administrator.

Why it matters

A vulnerable controller can be abused to escalate a standard domain account up to Domain Administrator. NoPAC and sAMAccountName spoofing are independent conditions: a controller may be NoPAC-vulnerable while still blocking the rename (for example with ms-DS-MachineAccountQuota set to zero). Patching is the only complete fix.

Findings

Finding ID Title
NOPAC-001 NoPAC Vulnerability Detected

Tooling

  • NetExec: -M nopac (used by this check).
  • noPac: scanner and exploitation.

References