From 6030d2fcd52c762679d9e86fa95b4fe1c03cb23e Mon Sep 17 00:00:00 2001 From: Jakub Jelen Date: Mon, 12 Aug 2024 13:49:31 +0200 Subject: [PATCH] tests: Describe reason for using internal-sftp Signed-off-by: Jakub Jelen Reviewed-by: Andreas Schneider (cherry picked from commit deedc0e10814009fe3690a9826d3fc2b5182cb36) --- tests/client/torture_sftp_setstat.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tests/client/torture_sftp_setstat.c b/tests/client/torture_sftp_setstat.c index fb0ce95d..736e47c1 100644 --- a/tests/client/torture_sftp_setstat.c +++ b/tests/client/torture_sftp_setstat.c @@ -16,9 +16,10 @@ static int sshd_setup(void **state) { /* - * Without root permissions, the exec-ed SFTP server does not inherit some - * wrappers so we use internal-sftp for this test, which does not have this - * issue. + * The OpenSSH invokes the sftp server command with execve(), which does + * not inherit the environment variables (including LD_PRELOAD, which + * is needed for the fs_wrapper). Using `internal-sftp` works around this, + * keeping the old environment around. */ setenv("TORTURE_SFTP_SERVER", "internal-sftp", 1);