# GHSA-mj73-j457-8x9q: `Reader::open_mmap` unsoundly marks unsafe memmap operation as safe

> An attacker can cause undefined behavior or crashes by modifying a memory-mapped file, potentially leading to code execution or denial of service.

- **Severity:** Not scored
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Not stated
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 28 Nov 2025
- **Also known as:** RUSTSEC-2025-0132

## What is GHSA-mj73-j457-8x9q?

GHSA-mj73-j457-8x9q is a memory corruption vulnerability in maxminddb, published on 28 Nov 2025. 

### Official description

maxminddb prior to version 0.27 declared `Reader::open_mmap` as safe 
despite wrapping an inherently unsafe memmap2 operation with no
extra step done to guarantee safety. This could have led to undefined
behaviour if the file were to be modified on disk while the memory map
was still active.

## Which versions are affected by GHSA-mj73-j457-8x9q?

3 open source packages ship an affected version, including maxminddb.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `maxminddb` | crates.io | From 0.11.0 | 0.27.0 |
| `maxminddb` | crates.io | From 0.11.0 | 0.27.0 |
| `maxminddb` | crates.io | From 0.11.0 | 0.27.0 |

## How do I fix GHSA-mj73-j457-8x9q?

Upgrade maxminddb to 0.27.0 or later.

## Is GHSA-mj73-j457-8x9q being exploited?

There is no known exploitation of GHSA-mj73-j457-8x9q in the wild and no public exploit code.

## Fix prompt for AI coding agents

```text
Check this codebase for GHSA-mj73-j457-8x9q and fix it if it is affected.

What it is: GHSA-mj73-j457-8x9q is a memory corruption vulnerability in maxminddb, published on 28 Nov 2025. 
Exploitation: There is no known exploitation of GHSA-mj73-j457-8x9q in the wild and no public exploit code.

Affected packages and fixed versions:
- maxminddb (crates.io): affected from 0.11.0; fixed in 0.27.0
- maxminddb (crates.io): affected from 0.11.0; fixed in 0.27.0
- maxminddb (crates.io): affected from 0.11.0; fixed in 0.27.0

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/GHSA-mj73-j457-8x9q/ (Markdown: https://insights.sbomify.com/GHSA-mj73-j457-8x9q/index.md)
```

## Sources

- OSV: https://osv.dev/vulnerability/GHSA-mj73-j457-8x9q

---
From sbomify Insights: https://insights.sbomify.com/GHSA-mj73-j457-8x9q/
Summaries are generated and may contain mistakes; the official description above is the record.
