Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessEstablish unprivileged local shell on target
-
DeliveryLaunch memory-exhausting processes to induce OOM
-
ExploitWait for privileged user to trigger pam_usb authentication (sudo/login)
-
Executionxmalloc/xstrdup returns NULL in NDEBUG build
-
PersistNULL dereference crashes PAM module
-
ImpactAuthentication denied; users locked out of sudo and login
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A10:2025 - Mishandling of Exceptional Conditions
ASVS 5.0
V16 - Security Logging and Error Handling Null pointer safety, defensive checks
MITRE ATT&CK
1 technique across 1 tactic: Impact The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires that pam_usb is explicitly configured in the system's PAM stack for one or more services (sudo, login, su) - this is a deliberate, non-default deployment requiring administrator intervention to enable. The installed binary must have been compiled with NDEBUG defined, which is the standard condition for packages distributed by Debian, Fedora, and Arch Linux but not for custom source builds without that flag. The attacker must have an existing local presence on the system (a shell or running process) capable of allocating sufficient memory to trigger an OOM condition in the pam_usb process at the moment of authentication (CVSS AC:H reflects this timing requirement). Exploitation is bounded to availability impact only - no code execution, privilege escalation, or data exposure is possible via this vulnerability. Systems with generous free memory at authentication time are not practically exploitable even if vulnerable in principle. |
| Impact | The CVSS 5.1 score with vector AV:L/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H accurately characterizes this as a local, high-complexity denial-of-service with no confidentiality or integrity impact. AC:H reflects the realistic constraint that an attacker must time memory exhaustion to coincide with an authentication event, requiring a local foothold and deliberate coordination. PR:N is technically correct - triggering memory pressure requires no elevated privileges - but the overall attack chain requires some form of local presence on the system, which is a meaningful barrier. No EPSS score was provided in the intelligence data; exploitation probability cannot be quantified beyond what the CVSS vector implies. The vulnerability is absent from the CISA KEV catalog, and no POC or active exploitation has been reported. The real-world risk is elevated in multi-user or server environments where losing sudo access during a critical incident has severe operational consequences. The insidious aspect is that distribution-packaged installations are silently affected while source-built installations without -DNDEBUG are not - administrators may be unaware their packaged binary lacks the guard. No conflicting signals are present in the provided data. |
| Exploit ScenarioDerived | An unprivileged local user on a multi-user Linux system launches a memory-intensive process (e.g., repeatedly allocating large arrays) immediately before a privileged administrator attempts to authenticate via sudo during an incident response. With system memory exhausted, pam_usb's xmalloc() or xstrdup() returns NULL; because the NDEBUG-compiled binary contains no OOM guard, the caller immediately dereferences NULL, crashing the PAM module and causing sudo to report authentication failure. The administrator is locked out for the duration of the crash, potentially impeding emergency response. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – May 27, 2026
pam_usb prior to 0.9.0 crashes under memory pressure due to assert()-based OOM guards in src/mem.c that are silently stripped by standard distribution build flags, enabling a local denial-of-service against authentication subsystems. Any allocation failure in xmalloc(), xrealloc(), or xstrdup() returns NULL, which every caller then dereferences unconditionally - the intended abort-before-dereference guarantee exists only in debug builds, not in Debian, Fedora, or Arch Linux packages that define -DNDEBUG via CFLAGS. A local attacker who can induce memory pressure at authentication time causes the PAM module to crash, locking all users out of sudo and login for the duration of the crash. No public exploit has been identified at time of analysis and the vulnerability is not listed in the CISA KEV catalog.
RemediationAI
The primary fix is to upgrade to pam_usb 0.9.0, which replaces assert()-based OOM guards in src/mem.c with explicit NULL checks followed by unconditional abort() calls, ensuring the guard is present in all build configurations regardless of NDEBUG. The upstream fix commit is at https://github.com/mcdope/pam_usb/commit/d003e551b794a9e3774ff4720830fb7aadaa48bd. For systems that cannot upgrade immediately, an interim compensating control is to rebuild pam_usb from source omitting -DNDEBUG from CFLAGS, which restores the assert() behavior - but this requires managing custom packages outside the distribution's update path and may be overwritten on the next OS-level package update. A second partial mitigation is to ensure the system has sufficient free memory headroom during authentication windows by limiting concurrent memory-intensive workloads, though this is not a reliable or enforceable control. Distribution maintainers for Debian, Fedora, and Arch Linux should be notified to rebuild and ship updated packages from 0.9.0.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
pam_usb (CPE: cpe:2.3:a:mcdope:pam_usb:*:*:*:*:*:*:*:*) is a Linux PAM module that provides hardware-based authentication via removable USB media. Its memory allocation wrappers in src/mem.c - xmalloc(), xrealloc(), and xstrdup() - used assert(data != NULL) as their sole out-of-memory guard. The C standard (ISO/IEC 9899) specifies that the entire assert() expression, including its side effects, is elided when the translation unit is compiled with NDEBUG defined. Distribution-level packaging for Debian, Fedora, and Arch Linux routinely inject -DNDEBUG into CFLAGS for release builds, silently removing these guards from the compiled binary. With the guard absent, any failed heap allocation propagates a NULL return value that is immediately dereferenced by callers - a textbook CWE-476 (NULL Pointer Dereference) condition. Because pam_usb runs within the PAM stack loaded by privileged binaries such as sudo and login, a module crash translates directly into authentication failure at the OS level.
Know when Pam Usb gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
AV:L/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H
Primary rating from Vendor (GitHub_M) · only source for this CVE.
CVSS VectorVendor: GitHub_M
Lifecycle Timeline
2DescriptionCVE.org
pam_usb provides hardware authentication for Linux using ordinary removable media. Prior to 0.9.0, src/mem.c implemented out-of-memory guards for xmalloc(), xrealloc(), and xstrdup() using assert(data != NULL). The C standard specifies that all assert() expressions are compiled out when NDEBUG is defined at build time. NDEBUG is commonly defined in release and packaging builds (Debian, Fedora, Arch package flags all define it via -DNDEBUG in CFLAGS). With the guard removed, xmalloc/xrealloc/xstrdup silently return NULL on allocation failure. Every caller in the codebase dereferences the return value without a NULL check -- this is the intended design, as the guard was supposed to abort before the dereference. With the guard gone, any allocation failure causes a NULL pointer dereference, crashing the PAM module. A crash in a PAM module loaded by sudo or login causes authentication to fail for the duration of the crash, creating a local denial-of-service condition. An attacker who can induce memory pressure at authentication time can lock all users out of sudo and login. This vulnerability is fixed in 0.9.0.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
A null pointer dereference occurs when a program attempts to access memory through a pointer that has been set to NULL (address 0x0).
Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.
Authentication bypass in pam_usb before 0.9.1 allows remote unauthenticated attackers to reach the USB hardware-authenti
pam_usb versions 0.8.0 through 0.9.2 fail to recognize compressed-notation IPv6 addresses when evaluating the optional d
The deny_remote safeguard in pam_usb fails open on link-local IPv6 sessions, causing a remote login to be classified as
pam_usb through 0.9.2 can be pushed past its explicit XRDP deny rule by a local user who simply unsets the XRDP_SESSION
Authentication bypass in pam_usb prior to 0.9.0 lets a local user defeat the USB hardware-authentication factor by delet
XXE injection in pam_usb prior to 0.9.2 enables an attacker with write access to the root-owned configuration file to tr
Heap buffer overflow in pam_usb prior to 0.9.1 allows a local attacker with high privileges to corrupt heap memory on 32
XPath injection in pam_usb prior to 0.9.0 allows unauthenticated remote attackers to manipulate device-verification quer
Environment variable injection in pam_usb prior to version 0.9.2 allows a local authenticated user to bypass hardware US
PATH hijacking in pam_usb helper tools prior to version 0.9.0 allows a local low-privileged attacker who can manipulate
Non-atomic one-time pad file creation in pam_usb prior to 0.9.2 exposes the core replay-prevention mechanism to a local
Symlink race condition in pam_usb prior to 0.9.2 allows a local attacker to redirect one-time pad files to an attacker-c
EUVD-2026-32654
NVD
CVE.org
EPSS
Vulnrichment
GitHub
Exploit-DB