CactiApplication

CVE-2021-3816

MEDIUM · 5.4 CVSS v3.1 Published 2022-01-19
Mitigation only
No fix yet — a mitigation exists. There is no fixed release. A documented workaround reduces exposure in the meantime.
See remediation →
58/100
Remediation priority · Elevated
Remotely reachable

Official description Straight from the sourceThe vendor's or NVD's own wording, published unedited. Authoritative, but often terse — it says what broke, rarely what to do.

NVD · unedited
Cacti 1.1.38 allows authenticated users with User Management permissions to inject arbitrary HTML in the group_prefix field during the creation of a new group via "Copy" method at user_group_admin.php.

Technical summary Written by usOur analysis, written from the advisory, the CVSS vector and the affected-version data. It adds context the advisory leaves out, and never invents facts that are not in the source.

dbcve analysis · high confidence

Cacti 1.1.38 contains a stored HTML injection vulnerability in user_group_admin.php. Authenticated users with User Management permissions can inject arbitrary HTML into the group_prefix field when creating a new group via the Copy method, potentially leading to cross-site scripting (XSS) attacks when other users view the affected group.

MitigationImplement server-side input validation and output encoding for the group_prefix field. Sanitize any HTML/script content before storing and properly encode output when rendering. Consider updating to a patched version if available.

Verify against the referenced sources before acting — the references below are authoritative for this CVE, this summary is not.

Affected products & versions What the vendor confirmedThe version ranges the vendor confirmed as vulnerable. If your version sits inside a range here, treat yourself as exposed until you have upgraded.

NVD · CPE data
CactiApplication
Affected:= 1.1.38

CVSS breakdown How the score is builtThe industry scoring standard. It rates how the flaw is reached, what it takes to exploit, and what an attacker gains — the score is derived from those, not the other way round.

From the vector
Attack vector
Network
Complexity
Low
Privileges
Low
User interaction
Required
Scope
Changed
Confidentiality
Low
Integrity
Low
Availability
None

CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N

Am I affected? How to checkSteps we derive from the advisory and the affected-version data, so you can decide whether this CVE reaches your setup. They are a guide, not a scan — your own configuration is the authority.

dbcve checks

Work through these to decide whether this CVE applies to you.

  1. Identify the installed Cacti version
    Log into the Cacti admin interface and navigate to 'Configuration' > 'Settings' > 'General', or check the version.php file in the Cacti root directory. Alternatively, run: grep -i 'version' include/cacti_version.php 2>/dev/null || php -r 'include("include/cacti_version.php"); echo $cacti_version;'
    Affected if The installed version is exactly 1.1.38
  2. Verify if any user accounts have User Management permissions
    Log into Cacti as an administrator and navigate to 'Authentication' > 'Users' > 'User Management'. Examine each user account to see if the 'User Management' permission checkbox is enabled under their Realm Permissions section.
    Affected if Any user account has the 'User Management' permission enabled, particularly if that account is accessible to non-administrators or is shared
  3. Check for groups created via the Copy method with potentially malicious group_prefix values
    Access the Cacti database directly. Run query: SELECT id, name, group_prefix FROM user_auth_group ORDER BY id; Review the group_prefix field values for any HTML tags, script elements, or encoded characters that suggest injection.
    Affected if Any group record contains HTML tags (e.g., <script>, <img>, <iframe>) or JavaScript event handlers in the group_prefix field
  4. Inspect the user_group_admin.php file for the vulnerability
    Locate the file user_group_admin.php in the Cacti installation directory. Search for the 'group_prefix' field handling. Use: grep -n 'group_prefix' user_group_admin.php
    Affected if The file exists and processes the group_prefix field without server-side sanitization (the code does not encode or strip HTML tags before saving to the database)

A user is affected if they are running Cacti version 1.1.38, have the User Management permission enabled for any account, and there exists a group with unsanitized HTML in the group_prefix field that could trigger XSS when viewed.

Generated from the published advisory. Verify against your own configuration.

Check your environment

Paste your version and any relevant configuration and it will be compared against the affected criteria above. Do not include secrets or credentials.

AI-assisted, checked against the advisory. Informational, not a guarantee.

Remediation Closing itWhat it takes to close this. Where a vendor fix exists we point at it; where none exists we say so plainly, and can build one. Effort estimates are scoped from the advisory, not from your codebase.

dbcve · scoped
Mitigation available No clean upgrade yet — mitigate in the meantime
Mitigation

Implement server-side input validation and output encoding for the group_prefix field. Sanitize any HTML/script content before storing and properly encode output when rendering. Consider updating to a patched version if available.

Recommended fix Moderate confidence

Cacti 1.1.39 or later stable release

  1. 1. Verify current Cacti version is 1.1.38 by checking the About page or running: grep -r 'version' /var/www/html/cacti/include/global.php 2. Backup the Cacti database and configuration files before upgrading 3. Download Cacti 1.1.39 or later from the official Cacti website (www.cacti.net) 4. Extract and install the new version following the upgrade documentation 5. Alternatively, apply vendor-prov
Caveat Review upgrade notes for any database schema changes or template modifications between 1.1.38 and target version

Generated from the published advisory — verify against the referenced sources before acting.

Fix this in Cacti Scoped from the published advisory
  • Consultation2.0 h
  • Implementation3.0 h
  • Testing2.0 h
  • Review / QA2.0 h
9.0 hours of engineering $1,600
Get help mitigating

An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $2,560.

Scan for this in your stack

Free · runs locally
dbcve dependency scanner

Check whether your project pulls in CVE-2021-3816 — or any other known-vulnerable package — straight from your lock files. Free and open source; it runs locally and uploads nothing.

References Go to the primary sourcePrimary sources — vendor advisories, patches and trackers. Where our summary and a reference disagree, the reference wins.

Primary sources

Practitioner notes

Contributed

Peer-ranked notes from engineers who’ve handled CVE-2021-3816 in production — separate from our analysis above.

No notes yet

Be the first to add a field note for this CVE — a mitigation you’ve verified, a version caveat, or a link to a working fix. Sign in above to contribute.

What this is

A place for practitioners to share what actually worked: a mitigation you’ve tested, a configuration change, a version- or environment-specific caveat, or a link to a verified patch. The most useful notes rise to the top as peers upvote them, so the signal stays high.

What belongs here
  • Verified mitigations, workarounds, and config changes
  • Version or environment caveats, and links to real fixes
  • No weaponised exploit code, or anything meant to cause harm
  • No spam, self-promotion, credentials, or personal data