A folder's own configuration names no proxy for the fetch, and git's own folder name is not a repository name #184

Closed
opened 2026-11-11 05:55:46 +00:00 by james.maes · 0 comments
Owner

Two small hardening items from the security review of the 1.1.1 release candidate. Neither exposes a token; both make a stated rule hold everywhere.

  1. A folder's own git configuration does not decide where a sync's fetch goes (#139). That is enforced for URL rewrites and for the SSH program. A proxy named in the folder's own configuration is still honored. It should be refused in the same way, with a message that names the setting; a proxy in the user's global configuration stays theirs.

  2. A repository name is one safe folder name. Tree paths may not contain git's own folder name in any spelling Windows opens as that folder; a repository name is checked for that only on the Windows sync path. RepositoryPathResolver.TryValidateName should refuse it on every platform, so every caller (the WSL clone, the library on other platforms) gets the same answer.

Each with a regression test, and the threat model's T3 and T4 rows updated.

Two small hardening items from the security review of the 1.1.1 release candidate. Neither exposes a token; both make a stated rule hold everywhere. 1. **A folder's own git configuration does not decide where a sync's fetch goes** (#139). That is enforced for URL rewrites and for the SSH program. A proxy named in the folder's own configuration is still honored. It should be refused in the same way, with a message that names the setting; a proxy in the user's global configuration stays theirs. 2. **A repository name is one safe folder name.** Tree paths may not contain git's own folder name in any spelling Windows opens as that folder; a repository name is checked for that only on the Windows sync path. `RepositoryPathResolver.TryValidateName` should refuse it on every platform, so every caller (the WSL clone, the library on other platforms) gets the same answer. Each with a regression test, and the threat model's T3 and T4 rows updated.
james.maes added the bug label 2026-11-11 05:55:46 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: KofTwentyTwo/gclo#184