CAPTCHA Bypass in WWBN/AVideo via Attacker-Controlled Length Parameter and Missing Token Invalidation on Failure
Date: 2026-04
Affected: composer/wwbn/avideo
Attack vector: other
Category: vulnerability-disclosure
Severity: Medium
CVE: CVE-2026-40935
CWE: CWE-804
CVSS: 5.3 (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N)

## Summary `objects/getCaptcha.php` accepts the CAPTCHA length (`ql`) directly from the query string with no clamping or sanitization, letting any unauthenticated client force the server to generate a 1-character CAPTCHA word. Combined with a case-insensitive `strcasecmp` comparison over a ~33-character alphabet and the fact that failed validations do NOT consume the stored session token, an attacker can trivially brute-force the CAPTCHA on any endpoint that relies on `Captcha::validation()` (user registration, password recovery, contact form, etc.) in at most ~33 requests per session. ## Details Three cooperating flaws in `objects/getCaptcha.php` and `objects/captcha.php` reduce CAPTCHA protection to a deterministic bypass. ### 1. External control of CAPTCHA strength (`objects/getCaptcha.php:7`) ```php $largura = empty($_GET['l']) ? 120 : $_GET['l']; $altura = empty($_GET['a']) ? 40 : $_GET['a']; $tamanho_fonte = empty($_GET['tf']) ? 18 : $_GET['tf']; $quantidade_letras = empty($_GET['ql']) ? 5 : $_GET['ql']; // attacker-controlled $capcha = new Captcha($largura, $altura, $tamanho_fonte, $quantidade_letras); $capcha->getCaptchaImage(); ``` There is no minimum, no type-check, and no clamping. Requesting `/objects/getCaptcha.php?ql=1` causes the server to generate a single-character word and save it to the attacker's own PHP session. ### 2. Small alphabet stored in the session (`objects/captcha.php:33-39`) ```php $letters = 'AaBbCcDdEeFfGgHhIiJjKkL


Mitigations:

Architectural layers (MAESTRO):