summaryrefslogtreecommitdiff
path: root/t/t0062-revision-walking.sh
diff options
context:
space:
mode:
authorLibravatar Jeff King <peff@peff.net>2015-09-04 18:40:08 -0400
committerLibravatar Junio C Hamano <gitster@pobox.com>2015-09-04 15:50:33 -0700
commitaab40438511dd2e4505c0850478e79773aa6721c (patch)
treebe61efe6393da0de96020f89ee8892cffc0ac5bb /t/t0062-revision-walking.sh
parentGit 2.5 (diff)
downloadtgif-aab40438511dd2e4505c0850478e79773aa6721c.tar.xz
git_connect: clear GIT_* environment for ssh
When we "switch" to another local repository to run the server side of a fetch or push, we must clear the variables in local_repo_env so that our local $GIT_DIR, etc, do not pollute the upload-pack or receive-pack that is executing in the "remote" repository. We have never done so for ssh connections. For the most part, nobody has noticed because ssh will not pass unknown environment variables by default. However, it is not out of the question for a user to configure ssh to pass along GIT_* variables using SendEnv/AcceptEnv. We can demonstrate the problem by using "git -c" on a local command and seeing its impact on a remote repository. This config ends up in $GIT_CONFIG_PARAMETERS. In the local case, the config has no impact, but in the ssh transport, it does (our test script has a fake ssh that passes through all environment variables; this isn't normal, but does simulate one possible setup). Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t0062-revision-walking.sh')
0 files changed, 0 insertions, 0 deletions