# CVE-2026-77325: MapServer: Reflected XSS in WMS OpenLayers output via the `X-Forwarded-Host` header

Status: published. Published: 2026-11-20. Updated: 2026-11-24.

MapServer is a system for developing web-based GIS applications. From 6.0 until 8.6.5, MapServer's WMS OpenLayers output, selected by FORMAT=application/openlayers or template=openlayers, substitutes a request-derived online-resource value into a single-quoted JavaScript string in src/maptemplate.c. The prior remediation for GHSA-xqj6-vjqr-33vv used msEscapeJSonLikeString() to protect the JavaScript string but did not neutralize angle brackets, so attacker-controlled X-Forwarded-Host or X-Forwarded-Proto values can still terminate the script element at the HTML parser layer. Deployments that expose attacker-controlled PATH_INFO or map= values reaching the same string are also affected. An unauthenticated attacker can cause arbitrary JavaScript to execute in a victim's browser under the MapServer origin when the victim loads the crafted output. This issue is fixed in version 8.6.5.

## Remediation

No remediation reported in collected sources

## Affected products and versions

- MapServer / MapServer: >= 6.0, < 8.6.5 (affected). Source: CNA: GitHub_M
-  / MapServer OpenLayers viewer (MapServer OpenLayers viewer): >= 6.0 (affected, GitHub advisory range). Source: GitHub GHSA-52rr-p4x5-2x6x

## Severity and prioritization

- 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; source: CNA: GitHub_M

- 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; source: NVD: security-advisories@github.com

- CISA KEV: No listing in collected sources

- EPSS: 0.47% as of 2026-11-23; percentile 41.87%

- SSVC: exploitation none; automatable no; technical impact partial; source ADP: CISA-ADP

- Weaknesses: CWE-79

## Exploit evidence

No exploit evidence in collected sources. This is not proof of no exploitation.

## References

- https://github.com/MapServer/MapServer/security/advisories/GHSA-52rr-p4x5-2x6x (CNA: GitHub_M; x_refsource_CONFIRM)

- https://github.com/MapServer/MapServer/pull/7544 (CNA: GitHub_M; x_refsource_MISC)

- https://github.com/MapServer/MapServer/pull/7554 (CNA: GitHub_M; x_refsource_MISC)

- https://github.com/MapServer/MapServer/commit/2e4229ff66f6eac1b270755a0ce0ce8debee4432 (CNA: GitHub_M; x_refsource_MISC)

- https://github.com/MapServer/MapServer/commit/57a5d592a4270137c20f33459d59d370b5374426 (CNA: GitHub_M; x_refsource_MISC)

- https://github.com/MapServer/MapServer/releases/tag/rel-8-6-5 (CNA: GitHub_M; x_refsource_MISC)

- https://github.com/MapServer/MapServer/commit/2e4229ff66f6eac1b270755a0ce0ce8debee4432 (security-advisories@github.com)

- https://github.com/MapServer/MapServer/commit/57a5d592a4270137c20f33459d59d370b5374426 (security-advisories@github.com)

- https://github.com/MapServer/MapServer/pull/7544 (security-advisories@github.com)

- https://github.com/MapServer/MapServer/pull/7554 (security-advisories@github.com)

- https://github.com/MapServer/MapServer/releases/tag/rel-8-6-5 (security-advisories@github.com)

- https://github.com/MapServer/MapServer/security/advisories/GHSA-52rr-p4x5-2x6x (security-advisories@github.com)

- https://github.com/MapServer/MapServer/security/advisories/GHSA-52rr-p4x5-2x6x (GitHub Security Advisories; advisory)

## Provenance

- CNA: GitHub_M: https://www.cve.org/CVERecord?id=CVE-2026-77325; retrieved 2026-11-24; source updated 2026-11-24

- NVD: https://nvd.nist.gov/vuln/detail/CVE-2026-77325; retrieved 2026-11-21; source updated 2026-11-20

- GitHub Security Advisories: https://github.com/MapServer/MapServer/security/advisories/GHSA-52rr-p4x5-2x6x; retrieved 2026-11-22; source updated 2026-08-20

- FIRST EPSS: https://api.first.org/data/v1/epss?cve=CVE-2026-77325; retrieved 2026-11-24; source updated Not reported

Revision: 17ad006cb3cd0828c6f7b9d98ac1a149758c0f4cb896577cee38c19cd7346e24

Canonical: https://y2.dev/cve/CVE-2026-77325

## Agent and API access

Public CVE pages, Markdown, and JSON are free to read without an account or API key.

- Public catalog: https://y2.dev/cve/index.json. Follow nextCursor with the same search, filters, sort, and limit (1–100). A null cursor marks the end.

- WebMCP: search_cve_disclosures, get_cve_disclosure, get_cve_page_markdown, get_y2_cve_access. Available in compatible browsers.

- Cyber API: https://api.y2.dev/api/v2/cyber/cves and https://api.y2.dev/api/v2/cyber/cves/{cveId}.

- Y2 Pro or Elite: create a workspace API key with the intel:cyber scope and send Authorization: Bearer <Y2_API_KEY>. Setup: https://y2.dev/docs/api/create-key.

- x402: Pay per request without an account or API key. Omit Authorization, read the HTTP 402 PAYMENT-REQUIRED challenge, validate its current requirements, and retry with PAYMENT-SIGNATURE through an authorized payment client. These browser tools never make payments. Guide: https://y2.dev/docs/api/x402.

- OpenAPI: https://y2.dev/api/openapi.yaml. Agent access metadata: https://y2.dev/cve/agent.json.

Collected public records only. Check source status for coverage and freshness.