Description
Insufficient Session Expiration vulnerability in OAuth token issuance in hexpm hexpm allows a user whose organization membership or session has ended to keep reading the organization's private packages and their documentation tarballs via a retained refresh token.

generate_refresh_token/4 in lib/hexpm/oauth/jwt.ex signs the refresh token with the same iss, aud and scope claims as the access token, so it carries the same repository:<org> scopes. The CDN service that serves private repositories verifies the signature and time claims and then authorizes from the scope claim, with no database lookup and no way to tell the two token kinds apart. Removing a member or revoking a session therefore takes effect at the CDN only when the 30 day refresh token expires, instead of after the 30 minute access token lifetime. Access is read-only and limited to organizations the account belonged to when the token was granted.

This issue affects hex.pm: from 2025-10-10 before 2026-09-22.
Published: 2026-09-22
Score: 2.3 Low
EPSS: < 1% Very Low
KEV: No
Impact: Unauthorized Read‑Only Access to Private Artifacts
Action: Apply patch
AI Analysis

Impact

The vulnerability arises from the fact that a refresh token is signed with the same claims as an access token and the CDN service accepts either token as a repository credential without verifying whether it is a refresh or an access token. As a result, a user whose organization membership or session has ended retains the ability to view the organization's private packages and documentation tarballs until the 30‑day refresh token expires. The flaw is a CWE‑613 weakness, which permits session tokens to persist longer than intended and can lead to unintended data exposure.

Affected Systems

The affected vendor is hexpm, product hexpm. Versions from 2025‑10‑10 up to but not including 2026‑09‑22 contain the flaw.

Risk and Exploitability

The CVSS score of 2.3 classifies the issue as low severity. There is no EPSS score available, and it is not listed in the CISA KEV catalog. Based on the description, the likely attack vector is possession or exposure of a valid refresh token; an attacker can then use this token to read private artifacts from any organization the token was issued for. Because the CDN performs no database lookup to differentiate token types, the token remains valid for up to 30 days even after the associated session has been revoked. The exploit does not provide code execution but allows unauthorized read‑only access.

Generated by OpenCVE AI on September 22, 2026 at 17:54 UTC.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade hexpm to a release issued after 2026‑09‑22 that fixes the refresh‑token handling logic.
  • Configure the CDN or service layer to enforce a token‑type check or a database lookup for repository scopes, rejecting refresh tokens as repository credentials.
  • If an upgrade cannot be performed immediately, revoke all existing refresh tokens for affected organizations and force users to re‑authenticate, thereby limiting the window of exposure.

Generated by OpenCVE AI on September 22, 2026 at 17:54 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Tue, 22 Sep 2026 19:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'poc', 'Technical Impact': 'partial'}, 'version': '2.0.3'}


Tue, 22 Sep 2026 16:00:00 +0000

Type Values Removed Values Added
Description Insufficient Session Expiration vulnerability in OAuth token issuance in hexpm hexpm allows a user whose organization membership or session has ended to keep reading the organization's private packages and their documentation tarballs via a retained refresh token. generate_refresh_token/4 in lib/hexpm/oauth/jwt.ex signs the refresh token with the same iss, aud and scope claims as the access token, so it carries the same repository:<org> scopes. The CDN service that serves private repositories verifies the signature and time claims and then authorizes from the scope claim, with no database lookup and no way to tell the two token kinds apart. Removing a member or revoking a session therefore takes effect at the CDN only when the 30 day refresh token expires, instead of after the 30 minute access token lifetime. Access is read-only and limited to organizations the account belonged to when the token was granted. This issue affects hex.pm: from 2025-10-10 before 2026-09-22.
Title Refresh tokens accepted as private repository credentials at the CDN
First Time appeared Hexpm
Hexpm hexpm
Weaknesses CWE-613
CPEs cpe:2.3:a:hexpm:hexpm:*:*:*:*:*:*:*:*
Vendors & Products Hexpm
Hexpm hexpm
References
Metrics cvssV4_0

{'score': 2.3, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:L/VI:N/VA:N/SC:L/SI:N/SA:N'}


cve-icon MITRE

Status: PUBLISHED

Assigner: EEF

Published:

Updated: 2026-09-22T18:09:08.676Z

Reserved: 2026-09-17T14:30:02.046Z

Link: CVE-2026-86698

cve-icon Vulnrichment

Updated: 2026-09-22T18:06:11.415Z

cve-icon NVD

Status : Deferred

Published: 2026-09-22T16:18:05.993

Modified: 2026-09-22T19:16:54.993

Link: CVE-2026-86698

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-09-22T19:00:12Z

Weaknesses
  • CWE-613

    Insufficient Session Expiration