CVE-2026-114096: Dulwich 0.24.0 before 1.2.8 Symlink Write-Through via porcelain.checkout paths
Dulwich from 0.24.0 before 1.2.8 contains a symlink following vulnerability in porcelain.checkout(paths=[...]) that allows attackers to write arbitrary files by abusing raw os.open without ONOFOLLOW. Attackers can craft a repository where a worktree symlink points to .git/hooks/post-checkout, so restoring the file from a tag writes a malicious hook for code execution.
Affected Software
Event History
Frequently Asked Questions
Who is exposed to this issue?
Applications using Dulwich versions from 0.24.0 before 1.2.8 that invoke porcelain.checkout with an explicit paths list are exposed when operating on an attacker-crafted repository or worktree.
What does an attacker need to exploit it?
The attacker needs to craft a repository in which a worktree symlink points to .git/hooks/post-checkout and cause a file restoration from a tag through porcelain.checkout(paths=[...]). This can write a malicious post-checkout hook that executes code.
Is a normal checkout affected?
The reported vulnerable path is porcelain.checkout(paths=[...]), meaning the issue specifically involves checkout operations with an explicit paths list. The provided information does not establish that checkouts without paths are affected.
What should be done if upgrading is not immediately possible?
Do not run porcelain.checkout with explicit paths against untrusted repositories or worktrees. In particular, avoid restoring paths from tags where attacker-controlled symlinks could redirect writes into .git/hooks.