CVE-2026-54576: CWE-59: Improper Link Resolution Before File Access ('Link Following') in MidnightBSD mport
CVE-2026-54576 is a vulnerability in the MidnightBSD package manager 'mport' prior to version 2.7.8. The issue involves improper link resolution before file access during package installation, allowing a local attacker with write access to a target directory to replace files with symbolic links. This can cause privileged ownership or mode changes to be applied to unintended paths, potentially compromising filesystem integrity or permissions. The vulnerability is fixed in version 2.7.8.
AI Analysis
Technical Summary
The vulnerability in mport versions before 2.7.8 arises from the use of path-based lstat(), chown(), stat(), and chmod() system calls in the do_actual_install() function during package installation. Because these operations do not securely handle symbolic links, a local attacker with write permissions in the target directory can substitute a file with a symlink after the initial checks but before ownership or permission changes are applied. This allows the attacker to redirect these privileged changes to arbitrary filesystem locations, risking unauthorized modification of file ownership or permissions. The issue is addressed by fixes introduced in mport version 2.7.8.
Potential Impact
A local attacker with write access to the target directory can exploit this vulnerability to redirect privileged ownership and permission changes to attacker-controlled paths. This can lead to compromised filesystem integrity or unauthorized permission escalation on files outside the intended package installation scope. The vulnerability requires local access and write permissions, and the attack complexity is high due to timing requirements.
Mitigation Recommendations
Upgrade mport to version 2.7.8 or later, where this vulnerability is fixed. No other mitigation is necessary as the issue is resolved in the official patch.
CVE-2026-54576: CWE-59: Improper Link Resolution Before File Access ('Link Following') in MidnightBSD mport
Description
CVE-2026-54576 is a vulnerability in the MidnightBSD package manager 'mport' prior to version 2.7.8. The issue involves improper link resolution before file access during package installation, allowing a local attacker with write access to a target directory to replace files with symbolic links. This can cause privileged ownership or mode changes to be applied to unintended paths, potentially compromising filesystem integrity or permissions. The vulnerability is fixed in version 2.7.8.
CVSS v4.0
Score 5.8medium
Affected software
MidnightBSD
mport
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The vulnerability in mport versions before 2.7.8 arises from the use of path-based lstat(), chown(), stat(), and chmod() system calls in the do_actual_install() function during package installation. Because these operations do not securely handle symbolic links, a local attacker with write permissions in the target directory can substitute a file with a symlink after the initial checks but before ownership or permission changes are applied. This allows the attacker to redirect these privileged changes to arbitrary filesystem locations, risking unauthorized modification of file ownership or permissions. The issue is addressed by fixes introduced in mport version 2.7.8.
Potential Impact
A local attacker with write access to the target directory can exploit this vulnerability to redirect privileged ownership and permission changes to attacker-controlled paths. This can lead to compromised filesystem integrity or unauthorized permission escalation on files outside the intended package installation scope. The vulnerability requires local access and write permissions, and the attack complexity is high due to timing requirements.
Mitigation Recommendations
Upgrade mport to version 2.7.8 or later, where this vulnerability is fixed. No other mitigation is necessary as the issue is resolved in the official patch.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-06-15T19:15:27.343Z
- Cvss Version
- 4.0
- State
- PUBLISHED
Threat ID: 6aac65bf55bf5e2cf5fdf656
Added to database: 09/17/2026, 22:12:15 UTC
Last enriched: 09/17/2026, 22:15:01 UTC
Last updated: 09/18/2026, 01:52:38 UTC
Views: 4
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.