WWBN AVideo is missing CSRF protection in objects/commentDelete.json.php enables mass comment deletion against moderators and content creators
Date: 2026-04
Affected: composer/wwbn/avideo
Attack vector: other
Category: vulnerability-disclosure
Severity: Medium
CVE: CVE-2026-40929
CWE: CWE-352
CVSS: 5.4 (CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:L)

## Summary `objects/commentDelete.json.php` is a state-mutating JSON endpoint that deletes comments but performs no CSRF validation. It does not call `forbidIfIsUntrustedRequest()`, does not verify a CSRF/global token, and does not check `Origin`/`Referer`. Because AVideo intentionally sets `session.cookie_samesite=None` (to support cross-origin embed players), a cross-site request from any attacker-controlled page automatically carries the victim's `PHPSESSID`. Any authenticated victim who has authority to delete one or more comments (site moderators, video owners, and comment authors) can be tricked into deleting comments en masse simply by visiting an attacker page. ## Details ### Vulnerable endpoint: `objects/commentDelete.json.php` ```php // objects/commentDelete.json.php:1-35 <?php header('Content-Type: application/json'); global $global, $config; if (!isset($global['systemRootPath'])) { require_once '../videos/configuration.php'; } require_once $global['systemRootPath'] . 'objects/comment.php'; $obj = new stdClass(); $obj->error = true; $obj->msg = ''; $obj->id = intval(@$_REQUEST['id']); // <-- GET or POST $obj->status = false; if (empty($obj->id)) { $obj->id = intval(@$_REQUEST['comments_id']); } if (empty($obj->id)) { $obj->msg = __("ID can not be empty"); die(_json_encode($obj)); } $objC = new Comment("", 0, $obj->id); $obj->videos_id = $objC->getVideos_id(); $obj->status = $objC->delete(); // <-- destructive action, no CSRF c


Mitigations:

Architectural layers (MAESTRO):