Skip to main content

MidnightBSD mport EUVDEUVD-2026-82320

| CVE-2026-54577 LOW
Improper Input Validation (CWE-20)
2026-09-17 GitHub_M
2.0
CVSS 4.0 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Operator runs mport audit with leading option
  2. Exploit
    Stale optind passes option token to audit_package
  3. Execution
    Wrong token audited, package skipped
  4. Impact
    Vulnerable package reported clean and left unpatched

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V2 - Validation and Business Logic Input validation, allowlisting
Exploitation Conditions

Triggered when the operator or automation invokes mport's audit command with an option (such as -r) placed before the package name on versions prior to 2.7.8; the stale optind/optreset state then causes audit_package() to receive the unadjusted argument (the option token) instead of the requested package. Limiting factors: requires local access and low privileges (PR:L) to run the tool, requires the specific option-before-argument invocation ordering (reflected as AT:P), is confined to MidnightBSD's mport package manager, and is not remotely exploitable - there is no adversary-controlled input path, so impact is limited to a self-inflicted false-negative in vulnerability auditing.

Impact

This is a genuinely low-risk issue and the signals are internally consistent. The vendor CVSS 4.0 score of 2.0 (AV:L/AC:L/AT:P/PR:L/UI:N/VC:N/VI:L/VA:N) reflects a local, low-privilege tooling logic bug, not a memory-corruption or privilege-escalation flaw. There is no EPSS score, no CISA KEV listing, and no public exploit - so exploitation status is 'no public exploit identified at time of analysis.' Critically, this is not an 'attack' in the conventional sense: the flaw is a parsing bug in mport's own audit command where stale optind/optreset state causes the option token (e.g. -r) to be audited instead of the intended package, yielding a false-negative. The real-world danger is a defensive blind spot - an operator or automated pipeline may believe a package is clean when it was never actually audited - rather than an offensive primitive. The vulnerable-integrity rating (VI:L) captures degraded trust in audit output; there is genuinely no confidentiality or availability impact, so the 'Information Disclosure' tag overstates and mislabels the effect. Priority is low: it matters only to the small population running MidnightBSD who rely on mport audit for vulnerability management.

Exploit ScenarioDerived

An operator (or CI/automation) runs mport audit -r somepackage to check whether an installed package is flagged as vulnerable. Due to the stale optind/optreset state, mport audits the -r option token instead of somepackage, returning a false-negative or useless result. The operator concludes the package is safe and leaves a genuinely vulnerable package installed and unpatched. No public exploit code exists; the flaw is triggered by ordinary option-before-argument usage rather than by a malicious actor.

Monitor Track and reassess. Why: LOW severity (CVSS 0.1-3.9).
Patch available 0.2% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Sep 17, 2026

MidnightBSD's mport package manager, in all versions prior to 2.7.8, mis-parses the argument list for its 'audit' subcommand, so when an option such as -r is placed before the package name the tool audits the option token instead of the requested package and returns a false-negative result. The flaw is reachable only by a local user with low privileges who already has the ability to run mport, requires the specific option-before-argument invocation ordering, and is not remotely triggerable - there is no adversary-controlled input path. The practical consequence is that an operator or automation script may believe a vulnerable package is clean, leaving it unpatched; there is no public exploit identified at time of analysis and the issue is not listed in CISA KEV. Vendor-released patch: 2.7.8.

RemediationAI

Upgrade to mport 2.7.8, which is the vendor-released patched version containing the corrected argument handling ('optind = 1' plus 'optreset = 1' reset under MidnightBSD and use of the adjusted local_argc/local_argv when calling audit_package()); the fix landed via pull request https://github.com/MidnightBSD/mport/pull/149 and commit b897240dc8181c53fbee231e77f88657c1edb9a0, with the release at https://github.com/MidnightBSD/mport/releases/tag/2.7.8. If immediate upgrade is not possible, the practical compensating control is to avoid the vulnerable invocation pattern: run the audit subcommand with the package name as the first argument and without a leading option token (that is, do not place -r or other flags before the package name), since the defect only manifests when an option precedes the argument and stale optind state causes the option token to be audited instead of the package. Because this workaround depends on every operator and every automation script using the correct ordering, it is fragile; a second control is to independently verify audit results by manually comparing installed package versions against MidnightBSD security advisories or by querying the vulnerability index directly, at the cost of additional manual effort and a slower patch cadence. Auditing should be treated as unreliable on any version below 2.7.8, and scripts that consumed the tool's exit status or output for gating should be re-run after upgrading to confirm previously suppressed findings.

Affected VersionsENISA

mport < 2.7.8

Affected Packages

euvd mport fix: 2.7.8

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

CVE-2026-54577 is an improper input validation (CWE-20) defect in the argument-handling code of mport/mport.c, the CLI front end of the MidnightBSD package manager. The audit path in main() built option-adjusted copies of the argument vector (local_argc/local_argv derived by subtracting and advancing past optind) but then called audit_package() with the original, unadjusted argument entry. Because optind/optreset were not reset between the initial option scan and the subsequent use of the adjusted arguments, the parser could resume at a stale index and hand audit_package() the option token itself rather than the package name it was meant to inspect. MidnightBSD libc uses the non-portable optreset flag, which is why the fix wraps '#if defined(__MidnightBSD__) optreset = 1; #endif' together with 'optind = 1' before re-scanning argv with the final option string, then recomputes local_argc = argc - optind and local_argv = argv + optind so the audit routine receives the correctly positioned package argument. The same refactor was applied to the download path (-a/-d flags) and cleaned up const-correctness of edge/char pointers. The vulnerability class is a self-inflicted parsing error in a local administration utility: it does not cross a trust boundary, does not expose data, and does not permit code execution, but it degrades the integrity of a security-relevant audit result, which is why the assessed impact is integrity-only and low. The affected CPE is cpe:2.3:a:midnightbsd:mport, covering every release before 2.7.8.

Know when Mport gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (GitHub_M) PRIMARY 2.0 LOW
CVSS:4.0/AV:L/AC:L/AT:P/PR:L/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N
vuln.today AI 2.5 LOW

Local CLI tool (AV:L) run by an operator (PR:L); only triggers under specific option-before-argument ordering (AC:H); sole impact is a misleading audit result (I:L, C/A:N).

3.1 AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:L/A:N
4.0 AV:L/AC:L/AT:P/PR:L/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Local
Attack Complexity
Low
Attack Requirements
Present
Privileges Required
Low
User Interaction
None
Vulnerable system: Confidentiality
None
Vulnerable system: Integrity
Low
Vulnerable system: Availability
None
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

1
Patch available
Sep 17, 2026 - 18:19 EUVD

DescriptionCVE.org

mport is the MidnightBSD Package Manager. Prior to 2.7.8, the audit command in mport/mport.c computed option-adjusted local_argv and local_argc values but passed the original argument entry to audit_package(). When an operator or automation used an option such as -r before a package name, stale optind state and the unadjusted argument could cause mport to audit the option token instead of the requested package, producing a false-negative or useless result that could leave a vulnerable package unidentified. The corrected parsing resets optind and optreset before using the adjusted local arguments. This issue is fixed in version 2.7.8.

Threat Intelligence Overview

EPSS Score
0.2%
Top 95% exploitable
Prevalence
Rare
MidnightBSD is a niche hobby BSD fork with minimal production footprint
Data Quality
5 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity LOW
CISA KEV No
Public POC No
EPSS 0.2%
Patch available Yes
Active threat No
Deciding rule
LOW severity (CVSS 0.1-3.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Defer
Exploitation· derived
None
System Exposure· derived
Small
Automatable· derived
No
Human Impact· derived
Low

Priority Score

10
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +10
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

More in Mport

View all
CVE-2026-54580 HIGH
8.3 Sep 17

Package-index corruption and denial of package-management operations affect MidnightBSD mport before 2.7.8 when a malici

CVE-2026-54583 HIGH
8.3 Sep 17

Path traversal in the MidnightBSD mport package manager (libmport/fetch.c) before version 2.7.8 lets an attacker who con

CVE-2026-54581 HIGH
8.3 Sep 17

MidnightBSD's mport package manager prior to 2.7.8 can accept a tampered bootstrap package index as verified, because th

CVE-2026-54586 MEDIUM
6.0 Sep 17

On-path tampering with package-fetch traffic in MidnightBSD's mport package manager lets a network-positioned attacker s

CVE-2026-54585 MEDIUM
6.0 Sep 17

Path traversal in MidnightBSD mport before 2.7.8 allows a crafted package manifest to make the privileged sample-file ha

CVE-2026-54582 MEDIUM
6.0 Sep 17

Package file overwrite in MidnightBSD mport prior to 2.7.8 allows a crafted package installed with privileges to replace

CVE-2026-54575 MEDIUM
5.8 Sep 17

Path-racing and shell-invocation weaknesses in the MidnightBSD mport package manager (all versions prior to 2.7.8) let a

CVE-2026-54576 MEDIUM
5.8 Sep 17

Filesystem integrity compromise in MidnightBSD's mport package manager (versions prior to 2.7.8): a local user who alrea

CVE-2026-54587 MEDIUM
5.8 Sep 17

Symlink following and dot-dot path traversal in MidnightBSD mport prior to 2.7.8 lets a local attacker who can already w

CVE-2026-54584 MEDIUM
5.3 Sep 21

MidnightBSD's mport package manager before 2.7.8 trusts the TMPDIR environment variable when extracting package metafile

CVE-2026-54579 LOW
2.3 Sep 17

Spoofed or injected ICMP echo replies can steer mport's mirror-latency selection toward an attacker-chosen mirror and, i

CVE-2026-54578 LOW
2.0 Sep 17

Checksum verification in MidnightBSD's mport package manager before 2.7.8 can silently continue after a hashing failure,

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy