Why a Moodle role risk review matters on a self-hosted site
On a self-hosted Moodle, the most important security question is rarely about code. It is who can change the whole site. Teachers, managers, course creators and support staff often hold roles that look narrow but carry site-wide reach, and over years of rollouts those grants accumulate. A role risk review starts from the people and roles that hold the highest-impact permissions, then checks whether each one still needs them. Three grants deserve the closest look: site administrator status, roles that carry XSS trust, and the permissions set on default roles that every new user or course inherits.
Site administrators can change authentication, install plugins, alter configuration and reach data across every course, so each account in that group is effectively a control point for the platform. Roles with XSS trust allow users to enter content such as HTML that Moodle does not clean, which makes a compromised or careless account in that role a route to stored script running in other users' sessions. Default role permissions matter because a single change there silently widens what a large population can do. The review therefore checks who holds these grants, not only what the Moodle code is capable of.
This review is a configuration audit that you run inside your own infrastructure, with your own administrator accounts and logs. DeployOpen performs it as part of a fixed-scope engagement and delivers findings, recommended changes and evidence for your security and compliance teams. DeployOpen does not issue audit reports, attestations or certifications; if an independent assessment is needed, your auditor or certification body performs it. Before starting, confirm with your team who is authorized to approve role changes and how those approvals are recorded.
Which Moodle capabilities carry the most risk
Moodle grants power through roles, and a few of them reach far beyond a single course. The areas below are the ones where a single misassigned permission can expose user data, run code, or change the whole site. Review each one against your own site, because the exact capability names and role setup depend on your version and plugins.
Site administrator accounts
Site administrators can change settings, install plugins, and reach every course and user record on the site, so they sit at the top of the risk list. Compromise of one administrator account is usually a site-wide event. Check how many accounts hold the site administrator role, whether each one belongs to a named person, and whether any are shared or left over from former staff. Confirm that administrator accounts sign in through your identity provider with MFA where possible.
Moodle 5.3 notesRoles holding XSS trust
The XSS trust capability lets a role enter content that Moodle displays without filtering, so anyone holding it can inject scripts that run in other users' sessions. Treat it as close to administrator access. Identify every role that carries this capability, including custom roles created by course or category teams, and confirm that only trusted staff are assigned them. Use the security overview report and the role risk views in your version to list holders rather than relying on role names.
Backup and export of user data
Backup, restore, and data export functions let a holder copy course contents and, depending on settings, user records out of the site. A user with these rights can remove personal data from your control without changing anything visible in the course. Map which roles can run backups, restore courses, or export data, and check whether those roles include users outside the core teaching or support team. Confirm the logs record who ran each export.
Default roles for new users
Moodle assigns default roles at the system and course levels, and any account created through self-registration, a directory sync, or an enrolment plugin inherits them. A permissive default can grant new accounts more than they need on their first day. Review the authenticated user role, the guest and site home roles, and any enrolment default role, and confirm each grants only what a typical learner needs. Test with a newly created account to see what it can reach.
Delegated course and category roles
Course creators, category managers, and teachers with enrolment rights can grant access and change settings within their area, often without central review. Over time those delegations accumulate across hundreds of courses. Check which users hold manager or course creator roles at category level, whether assignments are tied to current staff, and whether any delegated role includes capabilities listed in the other cards above. Ask who approves new delegated assignments and how they are removed when people change roles.
Custom and plugin-added roles
Plugins and local customizations can add capabilities and roles that never appear in a standard review. A role created for a reporting tool or integration may quietly gain access to user data or web services. Inventory every custom role and any capability added by an installed plugin, then compare each against the list of risky capabilities you have already mapped. Repeat this check after each plugin install or upgrade, since new releases can add or rename capabilities.
Review methods and when each fits
This table compares four ways to review who holds administrator and XSS-trusted capabilities in Moodle, and when each one fits a small site or a large multi-department site. Read each row for what the method finds and, more importantly, what it misses, then combine methods rather than choosing one. The main takeaway is that the security overview report is a starting checklist, while only a periodic access review tied to HR or identity records shows whether the people holding risky roles still should.
| Review method | Best fit | What it finds | What it misses |
|---|---|---|---|
| Security overview report | Small sites and first passes on any site | Failed checks on site settings, including administrator and role-related warnings that Moodle flags | Who specifically holds a role, custom roles and context overrides, and whether a holder still needs access |
| Manual admin UI listing | Small sites with few administrators | Current site administrators and role assignments at system and category level | Overrides deep in course or module contexts, and users granted roles through cohorts or other indirect routes |
| Role definition and context override review | Large multi-department sites with custom roles | Capabilities granted in each role, including XSS-trust related permissions, and where overrides widen access | Whether the people assigned each role are still employed, still in the right department, or still require it |
| Periodic access review tied to HR or identity records | Large sites, regulated sites and any site with frequent staff movement | Accounts that no longer match an active employee, role holders outside their department, and stale privileged access | Configuration drift between reviews, so it works best alongside the report and definition checks |
How to run the role review step by step
This sequence turns a vague worry about too many powerful accounts into a dated list of who holds risky capabilities, why they hold them, and who approved each one. The output is a reduced grant set that a second reviewer can check against the live site.
Export the administrator and role assignment baseline
Before changing anything, the site administrator records the current list of users in the site administrators setting and every role assignment at system context, plus any category-level assignments that carry administrative capabilities. Save the export with the date and the Moodle version, so later comparisons have a fixed starting point. Store it where the review team can read it but ordinary administrators cannot quietly edit it. The step is done when the baseline file lists every account that holds a site-level or system-level role and a second person has confirmed the count matches what the admin interface shows.
Run the security overview report and log findings
Open the security overview report under site administration and run it on the live site, not a copy. Record each finding that touches roles, users, guest access, web services or file paths, along with its severity as shown by Moodle. Note which findings the team already accepts with a reason and which need action. This record is the reference for the rest of the review. The step is complete when every finding is written down with its current status and the report run date, and the team can explain any finding they plan to leave open.
Identify roles with XSS trust and backup capabilities
Using the role definitions page, list every role that carries the capability to allow content with trusted HTML or scripts, and every role that can run or restore backups, export user data or view other users' private files. Check both custom roles and the default roles that were changed at install time. Mark each capability as held by a role, and then list the accounts assigned to each role. Your check is a table that maps each risky capability to its roles and to the named users who hold them, with no capability left unmapped.
Check default roles for authenticated users
Review the permissions of the authenticated user role and other default roles, such as guest and the role applied on the site home, against the list from the previous step. Look for risky capabilities that every logged-in user inherits, because a single weak account would then carry them too. Compare the current permissions with the defaults in the Moodle version you run, and note every difference. The step is done when the team has a signed-off list of default-role permissions that differ from the standard set, each with a stated reason or a planned removal.
Remove or narrow unneeded grants
For each capability that no current job requires, remove it from the role or narrow the role's context so it applies only at the category or course where it is needed. Make changes in a test copy of the site first where possible, then apply them to production during a planned change window. Keep each change linked to a finding or to a named business need. The check is a comparison between the baseline export and a new export: every removed grant should be traceable to a recorded decision, and no account should have gained a capability during the change.
Record approval for each remaining privileged holder
For every administrator and every account holding a retained risky capability, record the name of the person who approved the access, the business reason, the role used, and the date of review. The approver should be someone outside the team that operates the site, such as the owner of the learning service or the security lead. Store the register alongside the baseline and findings. The step is complete when every privileged account has an approval entry and an owner, and the register can be matched to the live role assignments without gaps.
Re-run the report and schedule the next review
After changes are applied, run the security overview report again and compare it with the earlier findings log. Confirm that every item marked for action is resolved or has an accepted reason, and that no new findings appeared after the changes. Set a recurring review on the calendar, and repeat it after each Moodle upgrade or plugin installation, since both can alter default roles and capabilities. The check is a short written note comparing the two reports and naming the date of the next review, signed by the person who owns the site.
How the review differs by site type
A small site usually has one or two people who act as site administrators, a handful of teachers, and a default set of roles that nobody has looked at since installation. Risk tends to pile up in the administrator account itself, in a manager who was given site-wide rights for a one-off project, and in an informal habit of granting teachers extra capabilities so that courses work. The review is short enough that the site owner can run it personally, but they should do it with the security overview report open alongside the role definitions.
- Site administrator count: Confirm how many accounts hold the site administrator role and whether each one belongs to a named person who still needs it.
- Shared or generic accounts: Look for admin or support accounts used by several people, which make it impossible to attribute actions.
- Teacher roles with extra capabilities: Check whether teachers were given XSS-trusted or site-level capabilities to solve a single problem.
- Default role changes: Compare the authenticated user and guest roles with the defaults shipped in core.
- Dormant accounts with rights: Find privileged accounts that have not signed in for a long period.
Before closing the review, confirm the owner has a written list of every privileged account and the reason it exists.
A large institution tends to have many course managers, faculty administrators, and local IT staff, each holding roles at category or course level. Grants accumulate through delegation: a faculty admin is given a role that was copied from another role, a local IT team is added to the site administrator group for a migration, and the role changes are never reversed. Ownership is split, so no single team sees the full picture. The review needs a named owner for the site-wide view and separate owners for each category or tenant.
- Overlapping role assignments: Map every user who holds more than one role at system or category level, since effective capabilities are the sum of those roles.
- Copied roles: Look for custom roles cloned from broader roles that still carry capabilities the new purpose does not need.
- Category-level grants that reach too far: Check whether delegated admins can change roles or site settings beyond their own category.
- Ownership gaps: Confirm that each category has an accountable owner who signs off on its privileged holders.
- Temporary grants that became permanent: Find migration or project access that was never removed.
Close the review by checking that each delegated owner has signed off on their own list, and that a recurring review date is set.
When accounts come from SSO or an HR feed, users are created and removed automatically, and the risk shifts from manual grants to the mapping rules that decide who gets which role. A mapping that matches a broad attribute, such as a job title that includes the word manager, can give far more people administrative reach than intended. Removed staff may keep access if the feed does not deprovision them, and manual role assignments made by administrators can persist outside the sync. The review should therefore test the mapping rules, not only the accounts that exist today.
- Attribute-to-role mappings: Check each rule that assigns system or category roles from an SSO or directory attribute, and confirm the attribute values that trigger it.
- Manual grants that sit outside sync: Identify roles assigned by hand to users whose accounts are managed by the feed, since these may not be removed when the feed changes.
- Deprovisioning behavior: Confirm with the identity team how leavers are suspended, and test that a suspended account loses its roles.
- Service accounts used by integrations: List accounts created for web services or the HR feed and confirm their role scope is minimal.
- Identity provider admin rights: Confirm who can change the SSO configuration, since changes there can grant Moodle access to new users.
Before closing the review, run one test user through the mapping with a known attribute set and confirm the roles they receive match the intended design.
How the review moves from holders to remediation
The review starts with a complete list of everyone who holds site administrator rights or a role that can be trusted with XSS-capable content. Each holder is then checked against a documented business need. Where no need exists, the grant is narrowed or removed, and the security report is re-run to confirm the change. Re-running after upgrades and plugin installs, and scheduling a recurring access review, keeps the picture current. Check that every decision is recorded with its owner and date.
The decision path from listing privileged holders to recurring review.
Operational controls that keep role risk from returning
A role review is a snapshot. The four controls below keep the administrator list and the XSS-trusted roles from drifting back to where they were after the audit. Each one maps to a moment when risk usually re-enters: a new admin, a plugin install, an upgrade, or a departure that nobody processed.
Keep the administrator list short and named
Site administrator is a site-wide capability, so every account in that list should belong to a named person with a documented reason to hold it. Review the list against the people currently responsible for the site, not the people who once needed it. Remove shared or generic admin accounts and give each engineer a personal account. Ask who approves a new site administrator and where that approval is recorded.
Moodle releasesRe-run the review after plugin installs
A plugin can add capabilities, roles or web service functions that were not present during the last review. Treat every plugin install, update or removal as a trigger to re-check the security overview report and the role assignments that touch the new plugin. Confirm which role can install plugins and that installs happen through a change record, not directly on the production site.
Re-run the review after Moodle upgrades
Major and minor upgrades can change default roles and capability sets, so a configuration that was clean before an upgrade may not be clean after it. Moodle ships minor point releases every two months, so a fixed review point tied to each release keeps the check routine. For the current LTS line, Moodle 5.3 is released on 5 October 2026 with security support until 1 October 2029. Confirm your planned upgrade dates against this cycle.
- Minor release cadence
- Every two months
Tie account removal to leaver processes
Administrator and XSS-trusted accounts often outlive the people who held them, especially when staff leave a school, team or contractor engagement. Connect Moodle account disablement to the HR or identity provider leaver workflow so access ends when employment ends. Where Moodle authenticates through SSO, disabling the upstream account should also block Moodle sign-in, but confirm that suspended users are not left with active admin roles inside Moodle.
Log administrative changes
A reviewer needs to know who granted a role, who changed a capability and when a plugin was installed. Moodle keeps logs of events, so confirm that role assignments, configuration changes and plugin installs are captured and retained for the period your incident response needs. Export or forward logs to a location administrators cannot edit, and check that the log retention setting matches your audit requirements.
What changes in 5.3 for role risk visibility
Moodle 5.3 is the next long-term support release, released on 5 October 2026, with general support until 4 October 2027 and security support until 1 October 2029. If your site will sit on this line for several years, the role risk visibility improvements in 5.3 are worth reading before you finalize your review process. Read them in the Moodle 5.3 release notes and confirm exactly which screens, reports or warnings changed, and whether any of them touch the security overview report or the capability views you use to check site administrators and XSS-trusted roles. Do not assume a change covers a specific risk until you have seen it in the notes.
Plan the upgrade path before you plan the review. Sites must already run Moodle 4.4 or later to upgrade to 5.3, and 5.3 requires 64-bit PHP 8.3 or later (8.4 is supported), along with PostgreSQL 17, MySQL 8.4, MariaDB 11.4 or SQL Server 2019 or later. Ask your platform team which of these your current stack already meets, and whether a PHP or database upgrade must come first. A role audit run on an outdated stack gives you findings you may not be able to act on for a long time.
Test the 5.3 behavior on a staging copy of your production database and moodledata before you rely on any new visibility feature. Run your existing role review against the staging site, record the output, and compare it with production to see what changed, what is missing and what is newly flagged. Keep this comparison with your change records, since it shows the reviewer what the upgrade altered in your role risk picture rather than relying on the release notes alone.
What to confirm in your own Moodle before relying on this review
The role review only holds for the Moodle version, plugins and identity setup you actually run. The six checks below connect the role inventory to your environment, so each finding reflects what your site really grants.
Exact role and capability names
Role names, capability identifiers and default role assignments can differ between Moodle versions and between sites that were upgraded and sites installed fresh. Before you read the review as a list of risky grants, export the roles on your own site and compare the capability names with the release notes for your version. Confirm any capability you plan to restrict against your installed version rather than against a guide written for another release.
Moodle 5.3 notesRisky capabilities added by plugins
Third-party plugins can register their own capabilities, and some of those grant write access to content, users or external services. A role that looks safe in core may gain sensitive rights once a plugin is installed. List every installed plugin that defines capabilities, read its capability file, and decide whether each one belongs in a role you already restrict. Repeat this check after each plugin install or update.
Account lifecycle ownership
If your identity provider creates, disables and removes accounts, Moodle administrators may not be the right people to grant or revoke site roles at all. Confirm which system is the source of truth for joiners, movers and leavers, and whether an administrator account can also be created or changed inside Moodle without going through that process. A former staff member who keeps a site administrator role is a common finding, so check how deprovisioning reaches Moodle.
Roles that theme and integrations depend on
Themes, web service integrations and LTI tools often rely on a specific role or capability to function. Removing or narrowing a role during a review can break a dashboard, a mobile sync or a grade passback, and teams then restore broad rights to fix the outage. Map which roles each theme and integration needs before you change anything, and test those flows after each change in a staging copy.
Security report coverage on your version
The security overview report checks change between releases, and some checks may be absent, renamed or weighted differently on your version. Do not assume a clean report means every role risk is covered. Run the report on your own site, record which checks it performs, and list the role-related concerns you need checked that it does not test. Fill any gap with a manual review of the roles you identified.
Trust grants held outside the role model
Some risky access sits in settings that the role table does not show, such as who can run backups, who holds XSS trust in content or who can reach user data exports. Confirm with your own team and vendor documentation which of these settings you use and who manages them. Record each grant with its owner and the reason it exists, so the review can separate deliberate access from accumulated access.
Questions buyers ask before a Moodle role review
How long does a Moodle role review take?
Duration depends on how many roles the site has, how many people hold administrator or elevated capabilities, how many plugins add their own capabilities, and whether the site is a single instance or several. A small site with a short role list and few plugins takes less time than a multi-category site with custom roles and a large plugin set. Ask for a written scope that lists the roles, plugins and environments covered, then confirm the timeline against that list before work starts.
What does the client need to provide for a role review?
The review needs named owners who can answer questions about who should hold each role and why. It also needs a site administrator account or a supervised session with admin access, so the reviewer can read the security overview report, role definitions and user assignments. A staging copy of the production site is the safer place to test role changes, because edits to capabilities can affect live courses. Ask for a list of integrations that assign roles automatically, such as SSO or HR sync, since those feed into the review.
Can our own team run a Moodle role review?
Yes, an internal team can run the review if it has an administrator who understands Moodle roles, the security overview report, and the capability model. The work is mostly reading role definitions, checking which users hold site administrator and roles that carry XSS trust, and documenting each decision. Teams that do this in-house usually need a second reviewer to challenge assumptions, and they need time to test changes on a copy of the site before applying them to production.
What does an outside review add to our internal review?
An outside reviewer brings a second view of who holds risky capabilities and whether the role model matches stated policy. They can check default roles, backup permissions and user data access against your access model, and they document findings in a form your security and compliance teams can track. Outside work does not replace your own owners, who still approve every role change. Ask the reviewer how they will record findings, how they will handle disagreements about who needs a role, and how retesting after fixes will work.
What is included in a Moodle role review, and what is not?
A role review covers site administrators, roles with XSS trust, default roles, permissions to back up and export user data, and the findings the security overview report raises about these areas. It does not include penetration testing, which is a separate exercise that tries to exploit the running system. It also does not produce an audit report or certification. Independent auditors and certification bodies issue those, and a review only prepares evidence for them. Confirm the boundary in the written scope so nobody assumes a test was done when it was not.
Which factors make a Moodle role review more complex?
Complexity grows with the number of custom roles, the number of plugins that add capabilities, and how many systems assign roles automatically. An SSO or HR integration that maps group membership to Moodle roles needs to be checked alongside the roles themselves, because a mapping error can grant a risky role to many users at once. Multi-site or multi-category designs also add work, since delegated administrators may hold powers that need separate review. Plugins that were installed years ago and never reviewed often contribute the most unexpected capabilities.
Does a role review need a retest after fixes?
A retest is worth planning because role changes can have side effects, and a fix may not remove the access it targeted if another role or integration still grants it. Ask for the retest to be part of the written scope and to cover the same report checks and role lists as the first pass. Re-run the security overview report after upgrades and after any plugin installation, since both can add capabilities or change defaults.
Official Moodle sources for role and release checks
Before you change any role or capability, read the Moodle 5.3 release notes and the Moodle releases page. The release notes for your target version are the authority on what changed in role handling, capability defaults and upgrade prerequisites, so treat them as the first check in your review rather than a reference you consult later. The Moodle 5.3 release notes describe the role risk visibility improvements this topic relies on, and they state the upgrade floor, which is that sites must run Moodle 4.4 or later to upgrade to 5.3.
The Moodle releases page is where you confirm which branch your site is on and how long it stays supported. Check it before you decide whether a role change must be made now or can wait for the next scheduled upgrade. Moodle 5.3 is the next LTS, with general support until 4 October 2027 and security support until 1 October 2029, while 5.1 has security support until 19 April 2027. Confirm the dates on the page yourself, since your upgrade plan depends on them.
Record the version you reviewed, the release notes you read and the date of the review in your audit file. If your site is on an older branch, confirm with your upgrade team which role-related changes apply to your starting version, because the release notes for each version differ. Repeat this check whenever you plan an upgrade, because role defaults can change between releases and an audit done on one version does not cover the next.
How DeployOpen scopes and delivers a Moodle role review
DeployOpen reviews who holds administrator and XSS-trusted capabilities on your Moodle site, using the security overview report and a role-by-role audit of your own configuration. The review ends in a written findings list, fixes applied within the agreed scope, and a retest so you can see what changed.
How we scope
- The written scope names the Moodle version, the sites and roles in review, and the environment where access is checked.
- We agree which accounts, custom roles and default role assignments are in scope before any review work starts.
- Engagements are fixed-scope, so deliverables and timelines are agreed in writing before work begins.
How we build
- We run the security overview report and map each finding to the administrator and XSS-trusted capabilities it touches.
- We audit site administrator membership, role assignments and any roles that hold XSS trust, comparing them with the access you say each person needs.
- We test the highest-risk paths against your role setup and record how each finding was reproduced, including role backup and default role settings.
How we hand over
- You receive a findings report listing each risky capability, who holds it, the evidence, and a recommended change.
- Role and configuration changes are documented so your administrators can repeat the review after upgrades and plugin installs.
- A retest confirms which fixes are in place and which findings remain open, with the reasons recorded.
How we support
- Ongoing support, upgrades and continuous testing are available as retainers for sites that need regular role reviews.
- Ask us to confirm which Moodle release line your site runs, since role capabilities and the security report can change between releases.
- Ask for a quote based on the written scope, which sets out who performs each task and what your team must provide.

