Description
MapServer is a system for developing web-based GIS applications. Prior to 8.6.5, MapServer's PostgreSQL JOIN implementation in src/mappostgresql.c copies the source layer attribute selected by JOIN FROM into joininfo->from_value and embeds it without parameterization or escaping into a dynamically generated PostgreSQL query executed by PQexec(). When PostgreSQL JOIN support is enabled, an attacker who can control that source feature attribute can inject quote characters and SQL operators that alter the intended WHERE predicate. This second-order injection can cause unintended rows and JOIN attributes to be returned, potentially exposing information from unrelated PostgreSQL records. This issue is fixed in version 8.6.5.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| MapServer | MapServer | < 8.6.5 | — |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | mapserver | 8.6.5-1 | — |
| Debian 13 | mapserver | No fix yet | — |
| Debian 12 | mapserver | 8.0.0-3+deb12u2 | DLA-4935-1 |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 26.04 LTS | mapserver | No fix yet | — |
| Ubuntu 24.04 LTS | mapserver | No fix yet | — |
| Ubuntu 22.04 LTS | mapserver | No fix yet | — |
| Ubuntu 20.04 LTS | mapserver | No fix yet | — |
| Ubuntu 18.04 LTS | mapserver | No fix yet | — |
Show 1 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 16.04 LTS | mapserver | No fix yet | — |
Advisories 1
- DLA-4935-1 mapserver - security update Debian Security (DSA / DLA) · Nov 25, 2026
References
- https://github.com/MapServer/MapServer/security/advisories/GHSA-m3xh-ccmh-x8rw
- https://github.com/MapServer/MapServer/pull/7546
- https://github.com/MapServer/MapServer/pull/7566
- https://github.com/MapServer/MapServer/commit/05babb88314b8f022eb47a3ab1a00eb37f92085f
- https://github.com/MapServer/MapServer/commit/a39a299a03a767dd966bb40caf044539e7813bce
- https://github.com/MapServer/MapServer/releases/tag/rel-8-6-5