about summary refs log tree commit diff
path: root/sysdeps/generic
diff options
context:
space:
mode:
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>2023-11-06 17:25:35 -0300
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>2023-11-21 16:15:42 -0300
commita72a4eb10b2d9aef7a53f9d2facf166a685d85fb (patch)
tree13139f4c794d9e60c851b99f73ac3771ff09d9ee /sysdeps/generic
parent6c6fce572fb8f583f14d898e54fd7d25ae91cf56 (diff)
downloadglibc-a72a4eb10b2d9aef7a53f9d2facf166a685d85fb.tar.gz
glibc-a72a4eb10b2d9aef7a53f9d2facf166a685d85fb.tar.xz
glibc-a72a4eb10b2d9aef7a53f9d2facf166a685d85fb.zip
elf: Add GLIBC_TUNABLES to unsecvars
setuid/setgid process now ignores any glibc tunables, and filters out
all environment variables that might changes its behavior. This patch
also adds GLIBC_TUNABLES, so any spawned process by setuid/setgid
processes should set tunable explicitly.

Checked on x86_64-linux-gnu.

Reviewed-by: Florian Weimer <fweimer@redhat.com>
Reviewed-by: Siddhesh Poyarekar <siddhesh@sourceware.org>
Diffstat (limited to 'sysdeps/generic')
-rw-r--r--sysdeps/generic/unsecvars.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/sysdeps/generic/unsecvars.h b/sysdeps/generic/unsecvars.h
index 8278c50a84..81397fb90b 100644
--- a/sysdeps/generic/unsecvars.h
+++ b/sysdeps/generic/unsecvars.h
@@ -4,6 +4,7 @@
 #define UNSECURE_ENVVARS \
   "GCONV_PATH\0"							      \
   "GETCONF_DIR\0"							      \
+  "GLIBC_TUNABLES\0"							      \
   "HOSTALIASES\0"							      \
   "LD_AUDIT\0"								      \
   "LD_DEBUG\0"								      \