CVE-2026-62268: borg extract might modify out-of-tree files when extracting maliciously crafted archives
A maliciously crafted archive could contain a symlink (e.g. “evil” -> “/etc”) followed by an item below it (“evil/passwd”), or an item whose path embeds “..” (e.g. “a/../../etc/passwd”).
When extracting such items, borg followed the symlink / resolved the “..”, so it could delete or overwrite files outside the extraction directory.
In a quite similar scenario, a crafted archive could contain a slave hardlink item with the hardlink source pointing outside the extraction directory.
When extracting such an item, borg would hard-link the outside and the inside item.
Note: that sounds bad, but it is no big issue in practice: to create such a malicious archive, the attacker would need repository access and (for encrypted or authenticated repos) also the borg key and passphrase.
Affected: likely all borg releases before 1.4.5 (and also all borg 2.0.0 betas before b22).
References
- github.com/advisories/GHSA-gfp8-w835-v44j
- github.com/borgbackup/borg/commit/0ac568e290518c3bbe781459978720dde7fab224
- github.com/borgbackup/borg/commit/141888f2fabcd57a300547c2aa63212cb213924d
- github.com/borgbackup/borg/commit/2d632531028b09da8ab5d1450f89bebcc205d640
- github.com/borgbackup/borg/commit/3e9ed6d1ad6d3531b39c07b8ef3ecf41fce4437f
- github.com/borgbackup/borg/commit/4f37fdfed10b50559a0dd333b0d5581c642af329
- github.com/borgbackup/borg/commit/d907f2cb57337041c4fa55ca4682895535e5076b
- github.com/borgbackup/borg/releases/tag/1.4.5
- github.com/borgbackup/borg/releases/tag/2.0.0b22
- github.com/borgbackup/borg/security/advisories/GHSA-gfp8-w835-v44j
- nvd.nist.gov/vuln/detail/CVE-2026-62268
Code Behaviors & Features
Detect and mitigate CVE-2026-62268 with GitLab Dependency Scanning
Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Dependency Scanning using SBOM also detects vulnerabilities from proprietary advisories that this site does not include. Learn more about Dependency Scanning using SBOM →