CVE-2026-21622
Hexpm 2025-10-01 – 2026-03-05
Raw vector
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:L/SC:H/SI:H/SA:L/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:XSummary
CVE-2026-21622 is a critical-severity Insufficient Session Expiration (CWE-613) vulnerability in Hex Hexpm. Its CVSS base score is 9.5 (Critical).
Operationally, exploitation aligns with the MITRE ATT&CK technique Browser Session Hijacking (T1185); ranked at the 32th percentile by exploit likelihood (below the median); it is not currently listed in the CISA KEV catalog.
The strongest mitigations our analysis identified map to AC-12 (Session Termination) — see the control section below for these in your framework.
Deeper analysis AI-assisted summary
Synthesised by an AI model from the NVD description and linked references — a reading aid, not an authoritative source.
CVE-2026-21622 is an insufficient session expiration vulnerability in the hexpm/hexpm repository, specifically within the Elixir.Hexpm.Accounts.PasswordReset module and the lib/hexpm/accounts/password_reset.ex file, along with the can_reset?/3 routine. This flaw affects versions of hexpm from commit 617e44c71f1dd9043870205f371d375c5c4d886d up to but not including bb0e42091995945deef10556f58d046a52eb7884. Password reset tokens generated through the "Reset your password" flow lack time-based expiration and remain valid indefinitely until used, enabling potential account takeover as rated at CVSS 9.8 (AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H) and mapped to CWE-613.
An attacker can exploit this vulnerability remotely without privileges by obtaining an unused password reset token from a victim's exposed historical emails, such as those leaked in a data breach or mailbox archive. Upon receiving a password reset request, Hex sends an email with a link containing the token; if this email is compromised in a prior breach, the attacker can activate the token to reset the victim's password without needing ongoing access to their email account, resulting in full account takeover.
Advisories and the associated patch recommend updating to the fixed commit bb0e42091995945deef10556f58d046a52eb7884 or later, which enforces proper token expiration. Details are available in the GitHub security advisory GHSA-6r94-pvwf-mxqm, the CNA page at cna.erlef.org, and the OSV entry at osv.dev.
OWASP Top 10 for Web (2025)
EU & UK References
- 🇪🇺 ENISA EUVD: EUVD-2026-9876
Vulnerability Data
Insufficient Session Expiration vulnerability in hexpm hexpm/hexpm ('Elixir.Hexpm.Accounts.PasswordReset' module) allows Account Takeover. Password reset tokens generated via the "Reset your password" flow do not expire. When a user requests a password reset, Hex sends an email containing a reset link…
more
with a token. This token remains valid indefinitely until used. There is no time-based expiration enforced. If a user's historical emails are exposed through a data breach (e.g., a leaked mailbox archive), any unused password reset email contained in that dataset could be used by an attacker to reset the victim's password. The attacker does not need current access to the victim's email account, only access to a previously leaked copy of the reset email. This vulnerability is associated with program files lib/hexpm/accounts/password_reset.ex and program routines 'Elixir.Hexpm.Accounts.PasswordReset':can_reset?/3. This issue affects hexpm: from 617e44c71f1dd9043870205f371d375c5c4d886d before bb0e42091995945deef10556f58d046a52eb7884.
- CWE(s)
Related Threats
MITRE ATT&CK Enterprise Techniques
CVEs Like This One
Affected Assets
Mitigating Controls
Mitigating Controls (NIST 800-53 r5) AI
AC-12 directly requires automatic session termination after a defined period, structurally preventing reuse of expired session identifiers.
Mitigating Controls (NIST CSF 2.0) AI
Derived directly from the weakness types (CWEs) cited in the NVD entry via our AI-authored CWE→CSF cross-walk (authority under review) — links open the control.
Credential lifecycle management directly includes enforcing session expiration to prevent reuse.
Authorization policy enforcement and review covers terminating stale sessions to limit access scope.
Authentication mechanisms can incorporate session timeout checks but do not inherently address expiration policy.
Mitigating Controls (ISO/IEC 27001:2022 Annex A) AI
Derived directly from the weakness types (CWEs) cited in the NVD entry via our AI-authored CWE→ISO cross-walk (authority under review) — links open the control.
Automatic termination of inactive sessions and limits on connection duration shrink the window during which a hijacked or unattended authenticated session can be exploited.