summaryrefslogtreecommitdiff
path: root/t/t5570-git-daemon.sh
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2021-01-25 14:19:17 -0800
committerJunio C Hamano <gitster@pobox.com>2021-01-25 14:19:17 -0800
commitc7b1aaf6d6bb5746a98831854313ca8fccea600d (patch)
treeba09f9c7df3f2eb5a690b9a39be37915aebf4b18 /t/t5570-git-daemon.sh
parent9e409d7e0762ff55c2787b4a106bf80ab2d57471 (diff)
parent6aed56736b882f94c81293d1646d27d10241349c (diff)
downloadgit-c7b1aaf6d6bb5746a98831854313ca8fccea600d.tar.gz
Merge branch 'jk/forbid-lf-in-git-url'
Newline characters in the host and path part of git:// URL are now forbidden. * jk/forbid-lf-in-git-url: fsck: reject .gitmodules git:// urls with newlines git_connect_git(): forbid newlines in host and path
Diffstat (limited to 't/t5570-git-daemon.sh')
-rwxr-xr-xt/t5570-git-daemon.sh5
1 files changed, 5 insertions, 0 deletions
diff --git a/t/t5570-git-daemon.sh b/t/t5570-git-daemon.sh
index 8f69a7854f..0fbb194810 100755
--- a/t/t5570-git-daemon.sh
+++ b/t/t5570-git-daemon.sh
@@ -103,6 +103,11 @@ test_expect_success 'fetch notices corrupt idx' '
)
'
+test_expect_success 'client refuses to ask for repo with newline' '
+ test_must_fail git clone "$GIT_DAEMON_URL/repo$LF.git" dst 2>stderr &&
+ test_i18ngrep newline.is.forbidden stderr
+'
+
test_remote_error()
{
do_export=YesPlease