Description
Grav CMS before 2.0.16 contains a timing vulnerability in Utils::verifyNonce() that uses non-constant-time string comparison with the === operator instead of hash_equals() for CSRF nonce validation. Attackers can measure response timing differences to recover valid nonce values byte-by-byte through multiple requests, weakening CSRF protection below its intended security margin.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| getgrav | grav | < 2.0.16 | 2.0.16 |
Affected packages
| Ecosystem | Package | Affected | Fixed | Record |
|---|---|---|---|---|
| Packagist | getgrav/grav | < 2.0.16 | 2.0.16 | GHSA-38p6-h87p-r4cg |
References
- GitHub Security Advisory (GHSA-38p6-h87p-r4cg) vendor-advisory
- VulnCheck Advisory: Grav CMS before 2.0.16 Timing Attack via verifyNonce third-party-advisory