CVE-2026-16615
Linux Debian vulnerability analysis and mitigation

Overview

CVE-2026-16615 is a cryptographically weak pseudo-random number generator (PRNG) vulnerability in librest, the GNOME REST API access library. The flaw exists in librest's PKCE (Proof Key for Code Exchange) implementation for OAuth 2.0 authorization, which uses the GLib GRand function — a non-cryptographic PRNG — to generate the OAuth "code verifier." This allows an attacker to reverse-engineer the PRNG seed and predict or reconstruct the code verifier, enabling client impersonation during the OAuth 2.0 authorization flow. The vulnerability was reported on July 21, 2026, and publicly disclosed on July 22, 2026, affecting all versions of librest. It carries a CVSS v3.1 base score of 6.8 (Medium) (Github Advisory, Red Hat Bugzilla).

Technical details

The root cause is classified as CWE-338 (Use of Cryptographically Weak Pseudo-Random Number Generator). Specifically, librest's PKCE implementation calls GRand from the GLib API to generate the OAuth code verifier string, but GRand is designed for general-purpose randomness and does not provide cryptographic entropy. An attacker who can observe or infer timing or output characteristics of the PRNG can reconstruct the seed and predict the code verifier. Exploitation requires network access and user interaction (e.g., a victim initiating an OAuth flow), and the attacker must be in a position to intercept or race the authorization code exchange. No public proof-of-concept code has been identified at this time (Github Advisory, Red Hat Bugzilla).

Impact

Successful exploitation allows an unauthenticated attacker to bypass PKCE protections and impersonate the client application during the OAuth 2.0 authorization flow, gaining unauthorized access to protected resources on behalf of the victim user. This results in high confidentiality and integrity impact — an attacker could access sensitive user data and perform unauthorized actions within the scope of the compromised OAuth session. Availability is not directly affected, but the authentication bypass could enable further lateral movement or privilege escalation depending on the OAuth-protected service (Github Advisory, Red Hat Bugzilla).

Exploitation steps

  1. Reconnaissance: Identify applications using librest for OAuth 2.0 authentication with PKCE, particularly GNOME applications or services that initiate OAuth flows via librest.
  2. Seed recovery: Observe or infer outputs from the GRand PRNG (e.g., through timing analysis or by observing other PRNG-derived values from the same process) to reconstruct the internal PRNG seed.
  3. Code verifier prediction: Using the recovered seed, reproduce the GRand sequence to predict the OAuth code verifier string that librest will generate for the victim's authorization request.
  4. Intercept authorization code: Position to intercept or race the OAuth authorization code (e.g., via a malicious redirect URI, network interception, or by triggering the victim to initiate an OAuth flow).
  5. Token exchange: Submit the intercepted authorization code along with the predicted code verifier to the OAuth authorization server's token endpoint, bypassing PKCE validation and obtaining access tokens on behalf of the victim (Github Advisory, Red Hat Bugzilla).

Mitigation and workarounds

The primary remediation is to update librest to a patched version that replaces the GRand PRNG with a cryptographically secure random number generator (CSPRNG) for PKCE code verifier generation. As of disclosure, the GitHub Advisory lists affected and patched versions as "Unknown," so users should monitor the GNOME librest GitLab issue and Red Hat advisories for patch availability. As a workaround, consider restricting OAuth flows that rely on librest's PKCE implementation, implementing additional server-side validation to detect anomalous authorization patterns, and monitoring OAuth token issuance for unexpected client activity (Github Advisory, Red Hat Bugzilla).

Additional resources


SourceThis report was generated using AI

Related Linux Debian vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2026-66033HIGH8.7
  • Wolfi logoWolfi
  • libssh2
NoNoJul 24, 2026
CVE-2026-66032HIGH8.7
  • Wolfi logoWolfi
  • libssh2
NoNoJul 24, 2026
CVE-2026-66035HIGH7.7
  • Wolfi logoWolfi
  • libssh2
NoNoJul 24, 2026
CVE-2026-66034HIGH7.7
  • Wolfi logoWolfi
  • libssh2
NoNoJul 24, 2026
CVE-2026-64255NONEN/A
  • Linux Debian logoLinux Debian
  • linux
NoYesJul 24, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management