CVE-2026-40291 Chamilo LMS has Privilege Escalation via API User Role Modification

High 8.8 Published Updated

Authenticated students can escalate to admin privileges by modifying their own user roles via the API, granting full platform control.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Over the internet
Victim action needed
Not needed
Fix
None listed

What is CVE-2026-40291?

CVE-2026-40291 is a high-severity vulnerability in Chamilo Chamilo Lms, published on 14 Apr 2026. Any signed-in user can exploit it over the network, with no action from the victim.

Official description

Chamilo LMS is an open-source learning management system. In versions prior to 2.0.0-RC.3, an insecure direct object modification vulnerability in the PUT /api/users/{id} endpoint allows any authenticated user with ROLE_STUDENT to escalate their privileges to ROLE_ADMIN by modifying the roles field on their own user record. The API Platform security expression is_granted('EDIT', object) only verifies record ownership, and the roles field is included in the writable serialization group, enabling any user to set arbitrary roles such as ROLE_ADMIN. Successful exploitation grants full administrative control of the platform, including access to all courses, user data, grades, and administrative settings. This issue has been fixed in version 2.0.0-RC.3.

Weakness: CWE-863, CWE-269

Which versions are affected by CVE-2026-40291?

It affects 1 product.

Products include Chamilo Chamilo Lms.

How do I fix CVE-2026-40291?

No fix has been published for CVE-2026-40291 yet. Limit exposure of the affected software until one is available.

Is CVE-2026-40291 being exploited?

There is no known exploitation of CVE-2026-40291 in the wild and no public exploit code.

All Chamilo Chamilo Lms vulnerabilities

Sources

Also known as GHSA-7phx-w897-4c9x.

Is CVE-2026-40291 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free