GHSA-v4v2-8h88-65qj

Suggest an improvement
Source
https://github.com/advisories/GHSA-v4v2-8h88-65qj
Import Source
https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2023/11/GHSA-v4v2-8h88-65qj/GHSA-v4v2-8h88-65qj.json
JSON Data
https://api.test.osv.dev/v1/vulns/GHSA-v4v2-8h88-65qj
Aliases
Related
Published
2023-11-24T16:54:20Z
Modified
2023-12-07T22:59:07Z
Severity
  • 6.1 (Medium) CVSS_V3 - CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N CVSS Calculator
Summary
Attribute Injection leading to XSS(Cross-Site-Scripting)
Details

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
    
  4. Click Save and return to the interface. XSS occurs. screenshots: image

9d0603e634fb7da2e83a0a45dc0a36ac

Database specific
{
    "nvd_published_at": "2023-12-01T22:15:10Z",
    "cwe_ids": [
        "CWE-79"
    ],
    "severity": "MODERATE",
    "github_reviewed": true,
    "github_reviewed_at": "2023-11-24T16:54:20Z"
}
References

Affected packages

npm / uptime-kuma

Package

Affected ranges

Type
SEMVER
Events
Introduced
1.20.0
Fixed
1.23.7

Database specific

{
    "last_known_affected_version_range": "<= 1.23.6"
}