CVE-2025-55003: Mfa Totp Cache Bypass Via Whitespace

A TOTP code is placed into a replay cache without checking for leading/trailing whitespaces. Because some TOTP libraries ignore whitespace during validation, an attacker could bypass the cache logic by appending spaces, causing a new unique cache entry to be created for an identical token. Validate whitespace using `strings.TrimSpace` before constructing rep

Provally CuratedPublic repositoryMediumMedium confidenceVerifiedApache-2.0Goβ
greprules fetch cve-2025-55003-mfa-totp-cache-bypass-via-whitespace --engine opengrep

Description

A TOTP code is placed into a replay cache without checking for leading/trailing whitespaces. Because some TOTP libraries ignore whitespace during validation, an attacker could bypass the cache logic by appending spaces, causing a new unique cache entry to be created for an identical token. Validate whitespace using `strings.TrimSpace` before constructing rep