# CVE-2024-21496: Cross-site Scripting in github.com/greenpau/caddy-security

- Severity: Medium 6.1 (CVSS:3.1, scored by snyk) `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N/E:P`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.58%, higher than 48% of CVEs (2026-12-01)
- Public exploit code or proof of concept: 2 links below, marked "exploit"
- Published: 2024-02-17T05:00:02.407Z
- Modified: 2026-06-17T07:09:36.970Z
- Also known as: GHSA-ff72-ff42-c3gw, GO-2024-2559
- Weaknesses: CWE-79
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: snyk

## Description

All versions of the package github.com/greenpau/caddy-security are vulnerable to Cross-site Scripting (XSS) via the Referer header, due to improper input sanitization. Although the Referer header is sanitized by escaping some characters that can allow XSS (e.g., [&], [<], [>], ["], [']), it does not account for the attack based on the JavaScript URL scheme (e.g., javascript:alert(document.domain)// payload). Exploiting this vulnerability may not be trivial, but it could lead to the execution of malicious scripts in the context of the target user’s browser, compromising user sessions.

(As written by CVE List.)

## Affected

- github.com/greenpau/caddy-security: before *
- github.com/greenpau/caddy-security (Go): up to 1.1.23; all versions
- authcrunch caddy-security: no versions given

## Every score

- snyk: CVSS:3.1 6.1 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N/E:P`
- GitHub: CVSS:3.1 6.1 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N`
- GitHub: CVSS:4.0 Medium `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N`

## References

- <https://github.com/greenpau/caddy-security/issues/267> (exploit, issue-tracking, report, web)
- <https://blog.trailofbits.com/2023/09/18/security-flaws-in-an-sso-plugin-for-caddy/> (exploit, third-party-advisory)
- <https://security.snyk.io/vuln/SNYK-GOLANG-GITHUBCOMGREENPAUCADDYSECURITY-6249860> (third-party-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2024-21496> (advisory)
- <https://blog.trailofbits.com/2023/09/18/security-flaws-in-an-sso-plugin-for-caddy> (web)
- <https://github.com/advisories/GHSA-ff72-ff42-c3gw> (advisory)

## Sources

- CVE List: [CVE-2024-21496](https://www.cve.org/CVERecord?id=CVE-2024-21496), CVE Terms of Use, modified 2024-11-06
- GitHub Advisory Database: [GHSA-ff72-ff42-c3gw](https://github.com/advisories/GHSA-ff72-ff42-c3gw), CC-BY-4.0, modified 2024-11-06
- Go Vulnerability Database: [GO-2024-2559](https://pkg.go.dev/vuln/GO-2024-2559), CC-BY-4.0, modified 2026-03-03
- NVD: [CVE-2024-21496](https://nvd.nist.gov/vuln/detail/CVE-2024-21496), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2024-21496 · Whole record: https://cve.day/CVE-2024-21496.json · Rebuilt by cve.day 2026-11-25T22:58:36.887Z
