vetkit.php.crypto.insecure-random-token
A token, password, salt or nonce is generated with a non-cryptographic random source (rand / mt_rand / uniqid / lcg_value / microtime), so it can be predicted.
Last updated:
Suite: Security
php
A token, password, salt or nonce is generated with a non-cryptographic random source (rand / mt_rand / uniqid / lcg_value / microtime), so it can be predicted.
Category: SECURITY · Engine rule severity: WARNING
How to fix it
Use random_bytes() (bin2hex(random_bytes(32))) or random_int() for every security-relevant value.
References
Source: packages/engine/rules/sast/php.yml.
Generated from shipped rule definitions at build time. Matching is a review signal, not proof of exploitability. “generic” denotes text matching, not complete language or framework coverage. Runtime configuration and available tools affect whether a rule runs.