{"id":"UBUNTU-CVE-2026-54355","details":"MapServer is a system for developing web-based GIS applications. From 6.0 until 8.6.4, MapServer's OpenLayers HTML output for SERVICE=WMS&REQUEST=GetMap&FORMAT=application/openlayers reflects an attacker-controlled X-Forwarded-Host value received as HTTP_X_FORWARDED_HOST through msBuildOnlineResource(), processLine(), and the [mapserv_onlineresource] substitution in src/maputil.c and src/maptemplate.c without escaping it for a single-quoted JavaScript string. When the deployment trusts the forwarded header and does not configure a fixed ows_onlineresource or MS_ONLINERESOURCE value, embedded single quotes can escape the generated URL string. An unauthenticated attacker can craft a URL that executes arbitrary JavaScript in the MapServer site origin when opened by a victim, enabling access to sessions or tokens, same-origin data and requests, and actions as the victim. This issue is fixed in version 8.6.4.","modified":"2026-09-21T21:39:47.100556383Z","published":"2026-09-21T00:00:00Z","upstream":["CVE-2026-54355"],"references":[{"type":"REPORT","url":"https://ubuntu.com/security/CVE-2026-54355"},{"type":"REPORT","url":"https://www.cve.org/CVERecord?id=CVE-2026-54355"},{"type":"REPORT","url":"https://github.com/MapServer/MapServer/security/advisories/GHSA-xqj6-vjqr-33vv"},{"type":"REPORT","url":"https://github.com/MapServer/MapServer/pull/7517"},{"type":"REPORT","url":"https://github.com/MapServer/MapServer/pull/7518"},{"type":"REPORT","url":"https://github.com/MapServer/MapServer/commit/edc1033c7963fcffd160d85cf430f49aaf4a1374"},{"type":"REPORT","url":"https://github.com/MapServer/MapServer/commit/ff17ef190caaeaa9002ac3d1c7969ec5315c345e"},{"type":"REPORT","url":"https://github.com/MapServer/MapServer/commit/edc1033c7963fcffd160d85cf430f49aaf4a1374"},{"type":"REPORT","url":"https://github.com/MapServer/MapServer/commit/ff17ef190caaeaa9002ac3d1c7969ec5315c345e"},{"type":"REPORT","url":"https://github.com/MapServer/MapServer/releases/tag/rel-8-6-4"},{"type":"REPORT","url":"https://mapserver.org/development/changelog/changelog-8-6.html#changelog-8-6"}],"affected":[{"package":{"name":"mapserver","ecosystem":"Ubuntu:16.04:LTS","purl":"pkg:deb/ubuntu/mapserver?arch=source&distro=xenial"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["7.0.0-4build1","7.0.0-5ubuntu1","7.0.0-7","7.0.0-8","7.0.0-8build1","7.0.0-9","7.0.0-9ubuntu1","7.0.0-9ubuntu2","7.0.0-9ubuntu3","7.0.0-9ubuntu3.1"],"ecosystem_specific":{"binaries":[{"binary_name":"cgi-mapserver","binary_version":"7.0.0-9ubuntu3.1"},{"binary_name":"libmapscript-java","binary_version":"7.0.0-9ubuntu3.1"},{"binary_name":"libmapscript-perl","binary_version":"7.0.0-9ubuntu3.1"},{"binary_version":"7.0.0-9ubuntu3.1","binary_name":"libmapserver2"},{"binary_name":"mapserver-bin","binary_version":"7.0.0-9ubuntu3.1"},{"binary_name":"python-mapscript","binary_version":"7.0.0-9ubuntu3.1"},{"binary_name":"ruby-mapscript","binary_version":"7.0.0-9ubuntu3.1"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-54355.json"}},{"package":{"name":"mapserver","ecosystem":"Ubuntu:18.04:LTS","purl":"pkg:deb/ubuntu/mapserver?arch=source&distro=bionic"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["7.0.6-2build1","7.0.7-1","7.0.7-1build1","7.0.7-1build2"],"ecosystem_specific":{"binaries":[{"binary_version":"7.0.7-1build2","binary_name":"cgi-mapserver"},{"binary_name":"libmapscript-java","binary_version":"7.0.7-1build2"},{"binary_name":"libmapscript-perl","binary_version":"7.0.7-1build2"},{"binary_name":"libmapserver2","binary_version":"7.0.7-1build2"},{"binary_version":"7.0.7-1build2","binary_name":"mapserver-bin"},{"binary_name":"python-mapscript","binary_version":"7.0.7-1build2"},{"binary_name":"ruby-mapscript","binary_version":"7.0.7-1build2"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-54355.json"}},{"package":{"name":"mapserver","ecosystem":"Ubuntu:20.04:LTS","purl":"pkg:deb/ubuntu/mapserver?arch=source&distro=focal"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["7.4.1-1build1","7.4.1-1build3","7.4.2-1","7.4.2-1build1","7.4.3-1","7.4.3-1build2","7.4.3-2","7.4.3-2build1"],"ecosystem_specific":{"binaries":[{"binary_version":"7.4.3-2build1","binary_name":"cgi-mapserver"},{"binary_version":"7.4.3-2build1","binary_name":"libmapscript-java"},{"binary_version":"7.4.3-2build1","binary_name":"libmapscript-perl"},{"binary_name":"libmapserver2","binary_version":"7.4.3-2build1"},{"binary_name":"mapserver-bin","binary_version":"7.4.3-2build1"},{"binary_version":"7.4.3-2build1","binary_name":"php-mapscript"},{"binary_version":"7.4.3-2build1","binary_name":"php-mapscript-ng"},{"binary_version":"7.4.3-2build1","binary_name":"python3-mapscript"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-54355.json"}},{"package":{"name":"mapserver","ecosystem":"Ubuntu:22.04:LTS","purl":"pkg:deb/ubuntu/mapserver?arch=source&distro=jammy"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["7.6.3-1~exp1ubuntu1","7.6.4-2","7.6.4-2build2"],"ecosystem_specific":{"binaries":[{"binary_version":"7.6.4-2build2","binary_name":"cgi-mapserver"},{"binary_version":"7.6.4-2build2","binary_name":"libmapscript-java"},{"binary_name":"libmapscript-perl","binary_version":"7.6.4-2build2"},{"binary_name":"libmapserver2","binary_version":"7.6.4-2build2"},{"binary_name":"mapserver-bin","binary_version":"7.6.4-2build2"},{"binary_version":"7.6.4-2build2","binary_name":"python3-mapscript"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-54355.json"}},{"package":{"name":"mapserver","ecosystem":"Ubuntu:24.04:LTS","purl":"pkg:deb/ubuntu/mapserver?arch=source&distro=noble"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["8.0.1-2build1","8.0.1-2build2","8.0.1-2build3","8.0.1-2build5","8.0.1-4ubuntu1","8.0.1-4ubuntu2"],"ecosystem_specific":{"binaries":[{"binary_name":"cgi-mapserver","binary_version":"8.0.1-4ubuntu2"},{"binary_name":"libmapscript-java","binary_version":"8.0.1-4ubuntu2"},{"binary_version":"8.0.1-4ubuntu2","binary_name":"libmapscript-perl"},{"binary_name":"libmapserver2t64","binary_version":"8.0.1-4ubuntu2"},{"binary_name":"mapserver-bin","binary_version":"8.0.1-4ubuntu2"},{"binary_name":"php-mapscript-ng","binary_version":"8.0.1-4ubuntu2"},{"binary_version":"8.0.1-4ubuntu2","binary_name":"python3-mapscript"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-54355.json"}},{"package":{"name":"mapserver","ecosystem":"Ubuntu:26.04:LTS","purl":"pkg:deb/ubuntu/mapserver?arch=source&distro=resolute"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["8.4.0-4build1","8.4.1-1","8.4.1-1build1","8.4.1-2","8.4.1-2build1","8.6.0-1","8.6.0-1build1"],"ecosystem_specific":{"binaries":[{"binary_name":"cgi-mapserver","binary_version":"8.6.0-1build1"},{"binary_name":"libmapscript-java","binary_version":"8.6.0-1build1"},{"binary_version":"8.6.0-1build1","binary_name":"libmapscript-perl"},{"binary_name":"libmapserver2t64","binary_version":"8.6.0-1build1"},{"binary_name":"mapserver-bin","binary_version":"8.6.0-1build1"},{"binary_version":"8.6.0-1build1","binary_name":"php-mapscript-ng"},{"binary_name":"python3-mapscript","binary_version":"8.6.0-1build1"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-54355.json"}}],"schema_version":"1.9.0","severity":[{"type":"CVSS_V4","score":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:N/VI:N/VA:N/SC:H/SI:H/SA:N"},{"type":"Ubuntu","score":"medium"}]}