Skip to main content

pam_usb EUVDEUVD-2026-123132

| CVE-2026-64667 MEDIUM
Out-of-bounds Read (CWE-125)
2026-11-11 GitHub_M
4.4
CVSS 3.1 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Gain local shell on host
  2. Delivery
    Spawn process with exactly-4096-byte cmdline
  3. Exploit
    Trigger PAM auth with DISPLAY set
  4. Execution
    Unterminated buffer scanned past allocation by strstr
  5. Impact
    SIGSEGV terminates host PAM process

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Bounds checking, read limits
MITRE ATT&CK

1 technique across 1 tactic: Collection

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires: (1) pam_usb version 0.9.2 or earlier present and configured in the host PAM stack; (2) local access as an existing user, since the vulnerable code runs during on-host PAM authentication; (3) the DISPLAY environment variable set, which is what causes pusb_get_tty_from_display_server to scan every process's /proc/<pid>/cmdline; and (4) a process whose cmdline read returns exactly 4096 bytes so the buffer ends without a NUL terminator. Turning the out-of-bounds read into a crash further depends on a hostile heap layout. Limiting factors: no remote vector (AV:L), an authenticated/local foothold is needed (PR:L), the info-disclosure is only a Boolean substring result, and the worst bounded outcome is a SIGSEGV of the PAM process rather than code execution. The complete fix is updating to 0.9.3 (read 4095 bytes, explicit NUL-termination, signed/unsigned read-return correctness), as stated by the advisory.

Impact

This is a genuinely low-priority, defense-in-depth-class issue despite being a memory-safety bug. The provided CVSS 3.1 vector (AV:L/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:L, base 4.4 Medium) is internally consistent with the description: exploitation is local (the flaw fires inside pusb_get_tty_from_display_server during on-host PAM authentication), requires an existing local user context (PR:L), and yields only a marginal boolean info-disclosure plus a potential SIGSEGV of the host PAM process (C:L/I:N/A:L). No EPSS score, no KEV entry, and no SSVC automatable/technical-impact fields were supplied, so the quantitative exploitation-probability picture is simply absent rather than conflicting. The vuln.today decision label is 'this_month' (routine patch cadence), not act_now or emergency, which aligns with the low severity. Signals do not conflict: a local-only, low-privilege, bounded-impact out-of-bounds read with no evidence of exploitation is a real bug worth patching on a normal cycle, not an urgent threat. The main caveat is that the availability impact is a crash of the authentication process, which for a security-critical PAM path could translate into a local denial of authentication under a crafted heap layout - but the advisory itself characterizes consequences as bounded.

Exploit ScenarioDerived

A local unprivileged user starts a process whose /proc/<pid>/cmdline is exactly 4096 bytes with no trailing NUL separator, then triggers a PAM authentication with DISPLAY set so pam_usb scans every process's cmdline. With a hostile heap layout, the unterminated buffer causes strstr() to read past the allocation and can crash (SIGSEGV) the host PAM process; the information-disclosure surface is limited to a Boolean substring match. No public exploit identified at time of analysis - the linked issue, pull request, and commit are the fix, not weaponized exploit code.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.2% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Nov 11, 2026

Heap out-of-bounds read in pam_usb 0.9.2 and earlier, where the PAM helper's DISPLAY-driven TTY discovery routine reads /proc/<pid>/cmdline into a 4096-byte heap buffer without guaranteeing NUL termination, so strstr() can scan past the allocation. Affected are Linux hosts with pam_usb <= 0.9.2 configured in the PAM stack; the flawed path runs during normal local authentication whenever DISPLAY is set, meaning an authenticated local user (CVSS AV:L/PR:L) is the realistic trigger context. Impact is bounded: the strstr() results are Boolean substring matches, so information disclosure is limited, and the worst realistic outcome is a SIGSEGV that kills the host PAM process, with no code execution demonstrated; no public exploit code was identified at time of analysis and the issue is not in CISA KEV. Vendor-released patch: 0.9.3.

RemediationAI

Update pam_usb to version 0.9.3, which is the vendor-released fix: it caps the cmdline read at CMDLINE_BUF_SIZE-1 bytes, explicitly NUL-terminates the buffer, replaces only the NULs actually read, propagates read errors and corrects the signed/unsigned handling of the read return value (commit d0a2e716241304cdb069adfaf54d2ede629d57fa, PR #426, release https://github.com/mcdope/pam_usb/releases/tag/0.9.3). The project security advisory GHSA-gc6f-5hpq-ghxh states that updating to 0.9.3 is the complete fix, and no separate workaround is documented there; issue #411 holds the underlying report and diff details. Because the vulnerable path only executes during on-host PAM authentication when DISPLAY is set, hosts that cannot patch immediately should track that prerequisite when prioritising, but the advisory treats the version upgrade as the resolution rather than a configuration-level mitigation.

Affected VersionsENISA

pam_usb < 0.9.3

Affected Packages

euvd pam_usb fix: 0.9.3

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 is a Linux PAM module providing hardware-based authentication via removable media. The defect sits in src/local.c in pusb_get_tty_from_display_server(), which xmallocs a 4096-byte buffer (xmalloc(4096)), memsets it, and then calls read(2) on /proc/<pid>/cmdline with a count of 4096. Because /proc/<pid>/cmdline is NUL-separated argv, the code then walks the buffer replacing NUL separators with spaces so that strstr() can look for the DISPLAY-related tokens. Two logic errors combine into CWE-125 (out-of-bounds read): the read may fill the entire 4096 bytes leaving no room for a terminator, and the existing loop condition mixes the signed int bytes_read against the index in a way that never writes a terminating NUL. Any process whose cmdline read returns exactly 4096 bytes therefore yields an unterminated buffer, and the subsequent strstr() calls can walk past the heap allocation. The upstream fix in PR 426 introduces a CMDLINE_BUF_SIZE macro and a dedicated pusb_read_cmdline() helper that reads bufsize-1 bytes, explicitly sets buf[n] = '\0', replaces embedded NULs only within the bytes actually read, propagates read errors (returns -1, caller continues), preserves errno, and corrects the signed/unsigned handling of the read return value; new cmocka unit tests cover short content, a full-buffer read, NUL replacement, and read errors. The function is reached during ordinary PAM authentication when the DISPLAY variable is set, so the read fires for every process inspected at auth time rather than only in an unusual code path.

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

Vendor (GitHub_M) PRIMARY 4.4 MEDIUM
AV:L/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:L
vuln.today AI 4.4 MEDIUM

Flaw runs during on-host PAM auth needing a local user context (AV:L/PR:L); impact is a marginal Boolean info leak (C:L) and a possible PAM-process crash (A:L), no integrity effect.

3.1 AV:L/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:L
4.0 AV:L/AC:L/AT:N/PR:L/UI:N/VC:L/VI:N/VA:L/SC:N/SI:N/SA:N

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Local
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
Unchanged
Confidentiality
Low
Integrity
None
Availability
Low

Lifecycle Timeline

1
Patch available
Nov 11, 2026 - 05:31 EUVD

DescriptionCVE.org

pam_usb provides hardware authentication for Linux using removable media. Prior to version 0.9.3, src/local.c (pusb_get_tty_from_display_server) allocates a 4096-byte cmdline buffer, reads up to 4096 bytes from /proc//cmdline, then replaces every NUL separator with a space. When read(2) returns exactly 4096 bytes for any process the function inspects, the buffer ends without a terminator and the subsequent strstr() calls scan past the allocation boundary. The function is invoked during normal PAM authentication when DISPLAY is set, so the read fires for every process at auth time. Consequences are bounded: strstr output is a Boolean substring match (limited info-disclosure surface) but a hostile heap layout can produce a SIGSEGV that terminates the host PAM process. This issue has been patched in version 0.9.3.

Threat Intelligence Overview

EPSS Score
0.2%
Top 95% exploitable
Prevalence
Low
niche Linux-only PAM module for USB hardware authentication, limited deployment
Data Quality
5 sources
Confidence: Medium

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.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.2%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Defer
Exploitation· derived
None
System Exposure· derived
Small
Automatable· derived
No
Human Impact· derived
Medium

Priority Score

22
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +22
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

A buffer overflow occurs when a program writes more data to a memory buffer than it was allocated to hold, causing the excess data to spill into adjacent memory regions.

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

Related Vulnerabilities in pam_usb Remote Detection and Memory Flaws

View all 4

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy