From: Marc Hoersken Date: Sat, 18 May 2019 21:28:09 +0000 (+0200) Subject: tests: fix permissions of ssh keys in WSL X-Git-Tag: curl-7_68_0~88 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=213c5aca7bfc74a6ae02b065c5f38a1e9ff54d62;p=thirdparty%2Fcurl.git tests: fix permissions of ssh keys in WSL Keys created on Windows Subsystem for Linux (WSL) require it for some reason. (This is one of several commits to support use of WSL for the tests.) Ref: https://github.com/curl/curl/pull/3899 --- diff --git a/tests/sshserver.pl b/tests/sshserver.pl index bcb2f1b3ab..197e8b872e 100644 --- a/tests/sshserver.pl +++ b/tests/sshserver.pl @@ -371,6 +371,9 @@ if((! -e $hstprvkeyf) || (! -s $hstprvkeyf) || logmsg 'Could not generate client key'; exit 1; } + # Make sure that permissions are restricted so openssh doesn't complain + system "chmod 600 $hstprvkeyf"; + system "chmod 600 $cliprvkeyf"; }