Skip to main content

librest EUVDEUVD-2026-47742

| CVE-2026-16615 MEDIUM
Use of Cryptographically Weak Pseudo-Random Number Generator (PRNG) (CWE-338)
2026-07-22 redhat GHSA-223h-642r-2f6v
6.8
CVSS 3.1 · Vendor: redhat
View

Attack ChainAIDerived

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

  1. Recon
    Position to observe OAuth flow
  2. Delivery
    User initiates librest OAuth authorization
  3. Exploit
    Capture code challenge derived from GRand output
  4. Install
    Brute-force 32-bit GRand PRNG seed
  5. C2
    Reconstruct code verifier
  6. Execute
    Submit verifier with intercepted auth code to token endpoint
  7. Impact
    Obtain OAuth access token as impersonated client

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A04:2025 - Cryptographic Failures
ASVS 5.0
V11 - Cryptography Cryptographic PRNG selection
Exploitation Conditions

Exploitation requires that the target application uses librest's built-in PKCE implementation for OAuth 2.0 authorization flows - specifically the GRand-based code verifier generation path. A legitimate user must actively initiate the OAuth authorization flow (UI:R per CVSS), providing the attacker with the authorization code and the window to act. The attacker must be positioned to observe PRNG-derived output (e.g., the code challenge or correlated GRand outputs) in order to recover the seed. Limiting factors: high attack complexity (AC:H) requiring PRNG seed reconstruction; exploitation is time-bounded by the authorization server's code expiry; the attacker cannot exploit this passively without an active user-initiated authorization event; applications using custom or alternative PKCE implementations unaffected. No special server-side configuration is required - the weakness exists in any librest OAuth client using the built-in PKCE flow.

Impact

The CVSS 3.1 vector AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:N scores 6.8, reflecting meaningful but non-trivial exploitation: the attacker must successfully recover GRand's PRNG seed (AC:H) within the bounded lifetime of an OAuth authorization code, and a legitimate user must first initiate the flow (UI:R). The high C and I scores are well-calibrated - successful client impersonation grants the attacker full access to OAuth-protected resources and the ability to perform actions as the victim client. No EPSS score was provided in the input data; exploitation likelihood cannot be quantified from available signals. The absence of a KEV listing and no confirmed POC means this is not known to be actively exploited. Real-world risk is bounded by the AC:H requirement: recovering a GRand seed is technically feasible given the small seed space, but requires the attacker to be positioned to observe PRNG-derived outputs and act within the authorization window. Applications using librest's PKCE flow in sensitive OAuth contexts (e.g., accessing protected GNOME Online Accounts or enterprise APIs) carry higher practical risk than those in low-sensitivity deployments.

Exploit ScenarioDerived

An attacker positioned to monitor or interfere with a target user's OAuth authorization flow - for example, via a network vantage point or a malicious application on the same host - observes the code challenge derived from librest's GRand-generated code verifier. The attacker brute-forces or reconstructs the 32-bit GRand seed from observed outputs, predicts the code verifier, and submits it to the OAuth token endpoint alongside the intercepted authorization code, obtaining a valid access token as the legitimate client. No public POC has been identified at time of analysis.

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

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

Alert me

AnalysisAIv1 – Jul 22, 2026

PKCE bypass in librest allows OAuth 2.0 client impersonation by exploiting a cryptographically weak pseudo-random number generator. The library's code verifier generation for PKCE (RFC 7636) uses GLib's GRand function - a non-cryptographic PRNG with a 32-bit seed space - rather than a CSPRNG, enabling a positioned attacker to recover the PRNG seed and reconstruct the code verifier to hijack the token exchange. Rated CVSS 6.8 with high confidentiality and integrity impact; no public exploit or CISA KEV listing identified at time of analysis.

RemediationAI

No patched version of librest has been confirmed in available references; the fix is currently tracked as an upstream issue at https://gitlab.gnome.org/GNOME/librest/-/issues/25. The correct fix requires replacing GRand with a CSPRNG for code verifier generation - suitable alternatives include GLib's g_random_bytes() when backed by OS entropy, or direct use of /dev/urandom via GLib I/O. Until a patched release is available, organizations should monitor https://access.redhat.com/security/cve/CVE-2026-16615 and https://bugzilla.redhat.com/show_bug.cgi?id=2504432 for patch announcements. As a compensating control, applications initiating OAuth flows via librest can be configured to enforce short authorization code lifetimes on the authorization server side, reducing the window available to a seed-recovery attacker, though this does not eliminate the underlying weakness. Switching to an alternative OAuth client library with CSPRNG-based PKCE is the most reliable interim mitigation for high-sensitivity deployments.

Affects your stack

Find out whether the stacks and servers you run are on an affected version.

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

librest is a GLib-based GNOME library for accessing RESTful web services, used by GNOME applications and GTK-based clients that implement OAuth 2.0 authorization flows. PKCE (Proof Key for Code Exchange, RFC 7636) is an OAuth 2.0 extension that prevents authorization code interception by binding the authorization request to a client-generated, cryptographically random 'code verifier.' The flaw (CWE-338: Use of Cryptographically Weak Pseudo-Random Number Generator) arises because librest calls GLib's GRand function - likely a Mersenne Twister or linear congruential generator - for this purpose. GRand's internal state is finite and its seed space is small (effectively 32-bit), meaning an attacker who observes sufficient PRNG output can recover the seed and reconstruct any future or concurrent verifier. The affected deployment context is confirmed via CPE cpe:2.3:a:red_hat:red_hat_enterprise_linux_10 and tracked upstream at gitlab.gnome.org/GNOME/librest/-/issues/25.

Know when Red Hat Enterprise Linux 10 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 (redhat) PRIMARY 6.8 MEDIUM
AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:N
vuln.today AI 6.8 MEDIUM

Network-reachable OAuth attack but requires PRNG seed recovery within auth window (AC:H) and active user flow (UI:R); full token access justifies C:H/I:H with no availability impact.

3.1 AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:N
4.0 AV:N/AC:H/AT:P/PR:N/UI:A/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N
SUSE MEDIUM
Red Hat 6.8 HIGH

Primary rating from Vendor (redhat).

CVSS VectorVendor: redhat

Attack Vector
Network
Attack Complexity
High
Privileges Required
None
User Interaction
Required
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
None

DescriptionCVE.org

A flaw was found in librest. The PKCE implementation for OAuth authorization uses the GRand function from the GLib API, a cryptographically insecure pseudo-random number generator. Because the generated "code verifier" lacks sufficient cryptographic entropy, a malicious actor can reverse-engineer the pseudo-random number generator (PRNG) seed to predict or reconstruct the code verifier string, allowing an attacker to bypass PKCE protections and successfully impersonate the client during the OAuth 2.0 authorization flow.

Threat Intelligence Overview

EPSS Score
0.4%
Top 65% exploitable
Prevalence
Low
GNOME ecosystem REST client library, limited enterprise footprint
Social Media
1
Sightings
Data Quality
7 sources
Confidence: High

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.4%
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
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
No
Human Impact· derived
Medium
Technical Impact
Total

Priority Score

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

Attack Technique

Authentication bypass attacks exploit flaws in the verification mechanisms that control access to systems and applications.

Affected Products (CPE)CVE.org

cpe:2.3:a:red_hat:red_hat_enterprise_linux_10:*:*:*:*:*:*:*:*
CVE-2026-18663 MEDIUM
5.9 Aug 12

Heap corruption via double-free in 389-ds-base's LDAP control parsing allows an unauthenticated remote attacker to crash

CVE-2026-4631 CRITICAL POC
9.8 Apr 07

Remote code execution in Cockpit's web interface allows unauthenticated attackers to execute arbitrary commands on the h

CVE-2026-4480 CRITICAL POC
9.0 May 26

Remote code execution in Samba's printing subsystem allows remote attackers to inject arbitrary shell commands via craft

CVE-2026-101258 HIGH POC
7.8 Oct 06

Ghostscript can execute arbitrary shell commands with the privileges of its process when it renders a crafted PostScript

CVE-2026-96889 HIGH POC
7.8 Sep 23

Use-after-free in librsvg during rendering of crafted SVG documents with nested XInclude directives and duplicate entity

CVE-2026-4775 HIGH POC
7.8 Mar 24

A signed integer overflow vulnerability exists in the libtiff library's putcontig8bitYCbCr44tile function that leads to

CVE-2026-114406 MEDIUM POC
6.8 Oct 21

The system CA trust store shipped in Red Hat's ca-certificates RPM packages includes eMudhra root authorities that signe

CVE-2026-18922 CRITICAL
9.8 Sep 07

Authentication bypass in 389 Directory Server (shipped as Red Hat Directory Server 11-13 and within RHEL 6-10) lets remo

CVE-2026-14544 CRITICAL
9.8 Jul 03

Remote code execution and privilege escalation in HPLIP (HP Linux Imaging and Printing) affects the hpcups print filter

CVE-2026-76578 CRITICAL
9.8 Sep 07

Unauthenticated privilege escalation in FreeIPA (Red Hat Identity Management) allows a remote attacker to gain genuine a

CVE-2026-102560 CRITICAL
9.8 Sep 29

A heap buffer overflow exists in libsoup's WebSocket permessage-deflate compression path: when a very large outbound mes

CVE-2026-5121 HIGH
7.5 Mar 30

Remote code execution in libarchive on 32-bit systems allows unauthenticated attackers to execute arbitrary code via spe

Vendor StatusVendor

SUSE

Severity: Moderate
Product Status
SUSE Liberty Linux 10 Fixed
SUSE Linux Enterprise Desktop 15 SP7 Affected
SUSE Linux Enterprise Desktop 15 SP7 Affected
SUSE Linux Enterprise High Performance Computing 15 SP7 Affected
SUSE Linux Enterprise Module for Desktop Applications 15 SP7 Affected

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