Skip to content

Attribute Injection leading to XSS(Cross-Site-Scripting)

Moderate
louislam published GHSA-v4v2-8h88-65qj Nov 24, 2023

Package

uptime-kuma

Affected versions

>= 1.20.0 && <= 1.23.6

Patched versions

1.23.7

Description

Summary

Google Analytics element Attribute Injection leading to XSS

Details

Since the custom status interface can set an independent Google Analytics ID and the template has not been sanitized, there is an attribute injection vulnerability here, which can lead to XSS attacks.
image

PoC

  1. Run the latest version of the louislam/uptime-kuma container and initialize the account password.
  2. Create a new status page.
  3. Edit the status page and change the Google Analytics ID to following payload(it only works for firefox. Any attribute can be injected, but this seems the most intuitive):
123123" onafterscriptexecute=alert(window.name+1),eval(window.name) a="x
  1. Click Save and return to the interface. XSS occurs.
    screenshots:
    image

9d0603e634fb7da2e83a0a45dc0a36ac

Severity

Moderate

CVSS overall score

This score calculates overall vulnerability severity from 0 to 10 and is based on the Common Vulnerability Scoring System (CVSS).
/ 10

CVSS v3 base metrics

Attack vector
Network
Attack complexity
Low
Privileges required
Low
User interaction
Required
Scope
Unchanged
Confidentiality
Low
Integrity
High
Availability
None

CVSS v3 base metrics

Attack vector: More severe the more the remote (logically and physically) an attacker can be in order to exploit the vulnerability.
Attack complexity: More severe for the least complex attacks.
Privileges required: More severe if no privileges are required.
User interaction: More severe when no user interaction is required.
Scope: More severe when a scope change occurs, e.g. one vulnerable component impacts resources in components beyond its security scope.
Confidentiality: More severe when loss of data confidentiality is highest, measuring the level of data access available to an unauthorized user.
Integrity: More severe when loss of data integrity is the highest, measuring the consequence of data modification possible by an unauthorized user.
Availability: More severe when the loss of impacted component availability is highest.
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:H/A:N

CVE ID

CVE-2023-49276

Weaknesses

Credits