Skip to main content
Menu
Advisories

Advisory

ALTCHA PHP: verifySolution bypasses HMAC signature check when challenge signature is absent

GHSA-82W8-65QW-GCH6Published Updated GitHub

Description

In altcha-org/altcha v2, the verifySolution method skips HMAC signature verification when the signature field is absent from the challenge payload, even when hmacSignatureSecret is configured.

An attacker who strips the signature key from the challenge JSON passes the condition as false, bypassing tamper-detection entirely. The PoW solution check then runs against unverified parameters — allowing an attacker to self-issue a low-difficulty challenge, solve it trivially, and submit a payload that verifies as true.

Impact: Complete CAPTCHA bypass on any deployment that sets hmacSignatureSecret (the recommended production configuration).

Fix: The check was split so that a missing signature is explicitly rejected when a secret is configured.

Affected versions