Git dubious-ownership Git refused to run because the repository folder is owned by a different system user.
Reviewed for reference consistency: April 11, 2026
Data Loss Risk
HIGH RISKGit stopped to prevent overriding unsaved work. Do not force commands without stashing or committing first.
What To Know
Where Did It Fail?
Commands That Trigger This
Technical Background
If an attacker can place a malicious `.git/config` file in a shared directory, they could trick your Git client into executing arbitrary commands with your user privileges.
Git enforces this check globally. If the ownership mismatch is intentional (like in Docker/WSL setups), the directory must be explicitly added to the `safe.directory` config list.
Underlying Causes
Frequently Asked Questions
Only if you completely trust the directory and the users who have write access to it (e.g., it is your own local development environment).