Highlights
Auth Bypass: 3 prior fixes. Scrutinize any change in this area.
src/Namshi/JOSE/Signer/OpenSSL/HMAC.php: most-fixed (3 issues). Treat as high-risk during review.
3 high-severity fixes in this history; regressions here are high-impact.
Recurring patterns
The bug types that recur here, drawn from past fixes, not open vulnerabilities.
Auth Bypass: Signature verification can be completely bypassed if the verification engine accepts weak or unexpected algorithms (such as the 'none' algorithm or RSA/HMAC confusion attacks) during token validation. Strict algorithm allowlisting must be enforced.
Auth Bypass: Failing to properly handle the exact return values of openssl_verify can lead to authentication bypasses, as an error value of -1 might be loosely evaluated or cast to boolean true (a valid signature state).
Timing Attack: HMAC verification is highly sensitive to timing attacks. Slight deviations in parameter ordering in comparison functions or inconsistencies in multibyte string length calculations (mb_strlen) can leak validation state information to attackers.