Skip to main content

Rejetto HFS CVE-2026-61500

CRITICAL
Use of Cryptographically Weak Pseudo-Random Number Generator (PRNG) (CWE-338)
2026-07-13 VulnCheck
9.3
CVSS 4.0 · Vendor: VulnCheck
Share

Severity by source

Vendor (VulnCheck) PRIMARY
9.3 CRITICAL
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/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:X
vuln.today AI
8.1 HIGH

Network, unauthenticated (PR:N/UI:N) path to admin RCE gives C/I/A High; AC:H reflects the sampling and PRNG-state reconstruction needed to recover the key.

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

Primary rating from Vendor (VulnCheck).

CVSS VectorVendor: VulnCheck

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
X

Lifecycle Timeline

3
Source Code Evidence Fetched
Jul 13, 2026 - 19:26 vuln.today
Analysis Generated
Jul 13, 2026 - 19:26 vuln.today
CVE Published
Jul 13, 2026 - 17:21 cve.org
CRITICAL 9.3

DescriptionCVE.org

Rejetto HFS 3.0.0 through 3.2.0 derives its session-cookie signing key from the non-cryptographic Math.random() generator and discloses outputs of the same generator to unauthenticated clients during login. A remote attacker can collect a small number of login responses, reconstruct the generator's state, recover the signing key, and forge a valid administrator session cookie, leading to full administrative access and remote code execution via the server_code configuration feature.

AnalysisAI

Administrator session forgery in Rejetto HFS (HTTP File Server) versions 3.0.0 through 3.2.0 lets a remote unauthenticated attacker derive the server's session-cookie signing key. Because HFS seeds that key from JavaScript's non-cryptographic Math.random() and simultaneously leaks outputs of the same generator to clients during login, an attacker can sample a few login responses, reconstruct the PRNG state, and mint a valid admin cookie - yielding full administrative control and remote code execution through the server_code configuration feature. No public exploit is identified at time of analysis, but the flaw was reported by VulnCheck/Horizon3.ai and a vendor patch (v3.2.1) exists.

Technical ContextAI

HFS is a lightweight, self-contained HTTP file server; the modern 3.x line is built on Node.js, where the vulnerable design relies on Math.random(). Math.random() is a fast, non-cryptographic PRNG (typically an xorshift128+ variant in V8) whose internal state can be recovered from a handful of observed outputs. This maps directly to CWE-338 (Use of Cryptographically Weak Pseudo-Random Number Generator): the same weak generator both derives the secret HMAC/signing key for session cookies and produces values exposed to unauthenticated clients during the login flow. Knowing the generator's outputs allows an attacker to solve for its state and thereby regenerate the signing key deterministically. The CPE cpe:2.3:a:rejetto:hfs:*:*:*:*:*:*:*:* confirms the affected component is the Rejetto HFS application itself across the 3.0.0-3.2.0 range.

RemediationAI

Vendor-released patch: 3.2.1 - upgrade every HFS instance to v3.2.1 or later immediately, as it addresses multiple session/authentication weaknesses affecting all prior 3.x versions (https://github.com/rejetto/hfs/releases/tag/v3.2.0...v3.2.1 changelog; release: https://github.com/rejetto/hfs/releases/tag/v3.2.1). Where an immediate upgrade is not possible, restrict network exposure of the admin interface by placing HFS behind a reverse proxy or firewall that limits access to the login/admin endpoints to trusted source IPs, which prevents an attacker from collecting the login responses needed to reconstruct the PRNG state (trade-off: legitimate remote administration must originate from allowlisted addresses). As a further compensating control, disable or lock down the server_code configuration feature and any admin account that is not strictly required, since server_code is the specific vector that converts a forged admin cookie into code execution (trade-off: loss of that scripting/automation capability). Rotate the server after patching, as any previously issued admin cookies should be considered compromised. Consult the VulnCheck advisory (https://www.vulncheck.com/advisories/rejetto-hfs-session-forgery-via-predictable-signing-key) for details.

Share

CVE-2026-61500 vulnerability details – vuln.today

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