CVE-2026-33649: AVideo's GET-Based CSRF in setPermission.json.php Enables Privilege Escalation via Arbitrary Permission Modification
Summary The plugin/Permissions/setPermission.json.php endpoint accepts GET parameters for a state-changing operation that modifies user group permissions. The endpoint has no CSRF token validation, and the application explicitly sets session.cookiesamesite=None on session cookies.
Published Mar 25, 2026
Affected packages
wwbn/avideo
- Ecosystem
- Composer (PHP)
- Affected
- <= 26.0
- Fixed in
- No patched version yet
- Check
composer show wwbn/avideo
Advisory details
From the GitHub Advisory Database (CC BY 4.0).
Summary
The plugin/Permissions/setPermission.json.php endpoint accepts GET parameters for a state-changing operation that modifies user group permissions. The endpoint has no CSRF token validation, and the application explicitly sets session.cookie_samesite=None on session cookies. This allows an unauthenticated attacker to craft a page with `` tags that, when visited by an admin, silently grant arbitrary permissions to the attacker's user group — escalating the attacker to near-admin access.
Details
The root cause is a combination of three issues:
1. `$_REQUEST` used instead of `$_POST` (accepts GET parameters):
plugin/Permissions/setPermission.json.php:14-24:
$intvalList = array('users_groups_id','plugins_id','type','isEnabled');
foreach ($intvalList as $value) {
if($_REQUEST[$value]==='true'){
$_REQUEST[$value] = 1;
}else{
$_REQUEST[$value] = intval($_REQUEST[$value]);
}
}
$obj = new stdClass();
$obj->id = Permissions::setPermission($_REQUEST['users_groups_id'], $_REQUEST['plugins_id'], $_REQUEST['type'], $_REQUEST['isEnabled']);The only authorization check is User::isAdmin() at line 10 — there is no CSRF token validation via isGlobalTokenValid().
2. Session cookies set to `SameSite=None`:
objects/include_config.php:134-141:
if ($isHTTPS) {
// SameSite=None is intentional: AVideo supports cross-origin iframe embedding
ini_set('session.cookie_samesite', 'None');
ini_set('session.cookie_secure', '1');
}This means the admin's session cookie is sent on cross-origin requests, including those initiated by `` tags on attacker-controlled pages.
3. The codebase's own security model requires CSRF tokens on state-mutating endpoints:
The comment at include_config.php:137-138 states: *"All state-mutating endpoints that are vulnerable to CSRF must instead enforce a short-lived globalToken (verifyToken)."* Other endpoints like saveSort.json.php and pluginImport.json.php enforce isGlobalTokenValid(), but setPermission.json.php does not.
Execution flow:
- Attacker hosts a page containing ``
- Admin visits the page (e.g., via link in forum, email, or embedded content)
- Browser issues GET request with the admin's
SameSite=Nonesession cookie User::isAdmin()passes because the request carries the admin's sessionPermissions::setPermission()grants PERMISSION_FULLACCESSVIDEOS (type=10) to user group 2- Any user in group 2 (including the attacker) now has full video admin access
The users_groups_id values are small sequential integers (typically 1-3 for default groups) and can be trivially enumerated.
PoC
Step 1: Attacker creates a page granting multiple permissions to their user group (ID 2):
<!DOCTYPE html>
<html>
<head><title>Interesting Video</title></head>
<body>
<h1>Check out this video!</h1>
<!-- Each img tag silently fires a GET request with admin's session cookie -->
<!-- PERMISSION_FULLACCESSVIDEOS (type=10) -->
<!-- PERMISSION_USERS (type=20) -->
<!-- PERMISSION_CAN_UPLOAD_VIDEOS (type=70) -->
<!-- PERMISSION_CAN_LIVESTREAM (type=80) -->
</body>
</html>Step 2: Attacker sends the link to an admin (social engineering, forum post, etc.)
Step 3: When the admin loads the page, all four `` tags fire simultaneously.
Expected response for each request (visible in browser dev tools):
{"id":"1"}Step 4: Verify — the attacker (a regular user in group 2) now has full video management, user management, upload, and livestream permissions without being an admin.
Impact
- Privilege escalation: A low-privileged user can gain near-admin permissions (full video access, user management, upload, livestream) by tricking an admin into loading a single page.
- No JavaScript required: The attack uses only `` tags, bypassing Content Security Policy restrictions and working even in contexts where scripts are blocked (email clients, forum BBCode, etc.).
- Zero interaction beyond page load: Unlike POST-based CSRF that requires form submission or JavaScript, this fires automatically when the page renders.
- Chaining: Multiple permissions can be granted simultaneously by embedding multiple `` tags. An attacker can grant their group all available permission types in a single page load.
- Blast radius: All users in the targeted group receive the escalated permissions, not just the attacker.
Recommended Fix
In plugin/Permissions/setPermission.json.php, change $_REQUEST to $_POST and add CSRF token validation:
<?php
header('Content-Type: application/json');
if (!isset($global['systemRootPath'])) {
$configFile = '../../videos/configuration.php';
if (file_exists($configFile)) {
require_once $configFile;
}
}
if(!User::isAdmin()){
forbiddenPage("Not admin");
}
// Enforce POST method and CSRF token
if ($_SERVER['REQUEST_METHOD'] !== 'POST') {
die(json_encode(array('error' => 'POST method required')));
}
if (!isGlobalTokenValid()) {
die(json_encode(array('error' => 'Invalid CSRF token')));
}
$intvalList = array('users_groups_id','plugins_id','type','isEnabled');
foreach ($intvalList as $value) {
if($_POST[$value]==='true'){
$_POST[$value] = 1;
}else{
$_POST[$value] = intval($_POST[$value]);
}
}
$obj = new stdClass();
$obj->id = Permissions::setPermission($_POST['users_groups_id'], $_POST['plugins_id'], $_POST['type'], $_POST['isEnabled']);
die(json_encode($obj));The AJAX call in getPermissionsFromPlugin.html.php:84-92 already uses type: 'post' but must also send the globalToken parameter in its data payload.
Credited to offset.
References
How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. No analysis has been written for this entry yet. Methodology
More Composer (PHP) vulnerabilities
All Composer (PHP) entriesCVE-2026-55173
AVideo has an incomplete fix of CVE-2026-33482: sanitizeFFmpegCommand still allows a single '&' (background operator), giving OS command execution at the same execAsync sh -c sink
high8.1No fixJun 23, 2026GHSA-7cqp-7cfv-6c3q
AVideo Meet plugin: anonymous-to-admin stored XSS via unescaped participant User-Agent in getMeetInfo.json.php Participants panel
medium5.4No fixJun 23, 2026CVE-2026-33684
AVideo's Privilege Escalation via Unguarded Permission Parameters in signUp API Allows Self-Granting Upload/Stream/Meet Permissions
medium5.3Jun 22, 2026CVE-2026-33692
AVideo Vulnerable to Unauthenticated .env File Exposure via Official Docker Compose Configuration
high7.5Jun 22, 2026CVE-2026-33731
AVideo has an Authorize.Net Webhook Signature Bypass that Enables Wallet Balance Inflation via Forged Payment Data
medium6.5Jun 22, 2026CVE-2026-49279
WWBN AVideo: Stored XSS via autoEvalCodeOnHTML Bypass in MessageSQLite WebSocket Handler (CVE-2026-43874 Bypass)
high7.7No fixJun 4, 2026
