Executive brief
mport is the package manager for MidnightBSD, responsible for installing and verifying the integrity of software packages. Prior to version 2.7.8, a flaw in the package verification logic could allow attackers to bypass checksum validation by causing hash computation failures, resulting in misleading integrity checks that hide tampered or corrupted files.
Technical details
The vulnerability is a logic error in mport_verify_package() within libmport/verify.c where the function could continue execution and compare checksums against stale data in the hash buffer after MD5File() or SHA256_File() failed. The root cause is improper error handling that does not skip asset verification when hashing fails, allowing an attacker to influence installed files or hashing conditions to either receive misleading integrity results or hide checksum failures entirely. Attack vector is local with no authentication required. The fix in version 2.7.8 wraps verification in proper transaction handling and corrects control flow to skip assets when hashing fails, ensuring only valid computed digests are compared.
Affected products
- MidnightBSD mport prior to 2.7.8
Timeline
- 2026-09-17: disclosed
- 2026-05-19: patched: Fix committed to main branch