Use of Cryptographically Weak Pseudo-Random Number Generator (PRNG) in FacturaScripts - #VU163117
Published: November 9, 2026
Vulnerability details
The vulnerability allows an unauthenticated remote attacker to attempt unauthorized access by predicting security tokens used to protect FacturaScripts accounts.
The vulnerability exists due to the use of PHP's cryptographically weak rand() generator in FacturaScripts' randomString() function when creating session tokens, API keys, and email verification codes. An unauthenticated remote attacker can attempt generator-state recovery to predict these tokens, but successful prediction was not demonstrated and is complicated by truncated output and multi-worker deployments.