CVE-2011-4297: Moodle Comment Capability Misconfiguration Vulnerability

moodle/moodle Updated 14 Dec 2025

Summary

13/05/2022
Yes i
Moderate
6.6

CVE-2011-4297: Moodle does not properly restrict comment capabilities. Affects moodle/moodle across 2 version ranges.

>= 2.0.0, < 2.0.4 >= 2.1.0, < 2.1.1

Fixed in 2.0.4 or 2.1.1, depending on the release line you run. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Your last release was probably never penetration tested Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

Moodle is an open-source learning platform designed to provide educators, administrators, and learners with a single robust, secure, and integrated system to create personalized learning environments. It supports various functionalities such as course management, user enrollment, and content delivery. However, certain versions of Moodle have a vulnerability that allows unauthorized users to post comments, potentially leading to spam or inappropriate content on front-page activities.

Vulnerability Detail

The vulnerability exists in comment/lib.php in Moodle versions 2.0.x before 2.0.4 and 2.1.x before 2.1.1. It fails to properly restrict comment capabilities, allowing remote attackers to exploit the guest role to post comments on front-page activities. This can lead to the dissemination of unwanted or harmful content, affecting the integrity and user experience of the platform.

How To Fix

Fixed versions by release line

The minimum fixed version depends on the release line you run.

  • >= 2.0.0, < 2.0.4 2.0.4
    composer require moodle/moodle:2.0.4
  • >= 2.1.0, < 2.1.1 2.1.1
    composer require moodle/moodle:2.1.1

Tip — Not sure which release line you're on? Vulert can find the fix for the version you are using. Scan free →

Workaround

As a temporary workaround, you can restrict guest access to commenting features by adjusting the role permissions in the Moodle administration settings. Navigate to Site administration > Users > Permissions > Define roles, and modify the guest role to limit comment capabilities.

Conclusion

The CVE-2011-4297 vulnerability in Moodle poses a risk by allowing unauthorized comment posting through improper restrictions. It is crucial to update to the latest patched versions to mitigate this risk. Additionally, utilizing tools like Vulert can help monitor and alert for such vulnerabilities in real-time.

See every vulnerability recorded for moodle/moodle →

Share this vulnerability

FAQ

CVE-2011-4297 is a vulnerability in Moodle that allows unauthorized users to post comments due to improper restrictions on comment capabilities.

Moodle versions 2.0.x before 2.0.4 and 2.1.x before 2.1.1 are affected by this vulnerability.

You can check your Moodle installation against this vulnerability using Vulert, which monitors open-source vulnerabilities in real-time. Visit Vulert Scanner to test your application without needing to sign up.

The risks include the potential for spam or inappropriate comments being posted on your Moodle site, which can disrupt the learning environment and harm the platform's reputation.

Yes, you can temporarily restrict guest access to commenting features by modifying the permissions for the guest role in the Moodle administration settings.

Related vulnerabilities

Recent vulnerabilities recorded for moodle/moodle.

How To Fix

Fixed versions by release line

The minimum fixed version depends on the release line you run.

  • >= 2.0.0, < 2.0.4 2.0.4
    composer require moodle/moodle:2.0.4
  • >= 2.1.0, < 2.1.1 2.1.1
    composer require moodle/moodle:2.1.1

Tip — Not sure which release line you're on? Vulert can find the fix for the version you are using. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback