Page MenuHomePhabricator

Fix an issue where "git" may be unable to read a temporary file in Diffusion
ClosedPublic

Authored by epriestley on Apr 20 2022, 4:31 PM.
Tags
None
Referenced Files
F17840788: D21759.id.diff
Sat, Jul 26, 9:34 PM
F17806842: D21759.diff
Fri, Jul 25, 2:16 PM
Unknown Object (File)
Jun 7 2025, 2:21 AM
Unknown Object (File)
May 20 2025, 4:22 PM
Unknown Object (File)
May 5 2025, 1:13 PM
Unknown Object (File)
Apr 30 2025, 9:36 AM
Unknown Object (File)
Apr 18 2025, 10:18 AM
Unknown Object (File)
Apr 18 2025, 9:55 AM
Subscribers
None

Details

Summary

Ref T13673. After the changes in that task, we may execute "git config -l ..." as a user other than the user we used to write this temporary file.

Use "--file -" to pass the data instead, avoiding use of temporary files. This makes us agnostic to filesystem permissions.

Test Plan

Viewed a Git repository with submodules in Diffusion with "ssh.user" configured as a user relatively isolated from the webserver user.

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

epriestley created this revision.
This revision was not accepted when it landed; it landed in state Needs Review.Apr 20 2022, 8:04 PM
This revision was automatically updated to reflect the committed changes.