linux/fs/proc
Thomas Weißschuh 34a86adea1 sysctl: always initialize i_uid/i_gid
[ Upstream commit 98ca62ba9e ]

Always initialize i_uid/i_gid inside the sysfs core so set_ownership()
can safely skip setting them.

Commit 5ec27ec735 ("fs/proc/proc_sysctl.c: fix the default values of
i_uid/i_gid on /proc/sys inodes.") added defaults for i_uid/i_gid when
set_ownership() was not implemented. It also missed adjusting
net_ctl_set_ownership() to use the same default values in case the
computation of a better value failed.

Fixes: 5ec27ec735 ("fs/proc/proc_sysctl.c: fix the default values of i_uid/i_gid on /proc/sys inodes.")
Cc: stable@vger.kernel.org
Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
Signed-off-by: Joel Granados <j.granados@samsung.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-08-19 05:45:28 +02:00
..
array.c fs/proc: do_task_stat: move thread_group_cputime_adjusted() outside of lock_task_sighand() 2024-03-15 10:48:22 -04:00
base.c procfs: block chmod on /proc/thread-self/comm 2023-09-19 12:22:52 +02:00
bootconfig.c proc: bootconfig: Add null pointer check 2022-04-08 14:24:12 +02:00
cmdline.c
consoles.c
cpuinfo.c
devices.c
fd.c procfs: prevent unprivileged processes accessing fdinfo dir 2022-05-18 10:26:50 +02:00
fd.h
generic.c proc: fix dentry/inode overinstantiating under /proc/${pid}/net 2022-06-09 10:23:10 +02:00
inode.c
internal.h
interrupts.c
Kconfig
kcore.c fs/proc/kcore: use page_offline_(freeze|thaw) 2021-06-30 20:47:28 -07:00
kmsg.c
loadavg.c
Makefile
meminfo.c
namespaces.c
nommu.c
page.c
proc_net.c proc: fix dentry/inode overinstantiating under /proc/${pid}/net 2022-06-09 10:23:10 +02:00
proc_sysctl.c sysctl: always initialize i_uid/i_gid 2024-08-19 05:45:28 +02:00
proc_tty.c
root.c
self.c
softirqs.c
stat.c fs/proc/uptime.c: Fix idle time reporting in /proc/uptime 2021-11-18 19:16:13 +01:00
task_mmu.c fs/proc/task_mmu: indicate PM_FILE for PMD-mapped file THP 2024-08-19 05:45:09 +02:00
task_nommu.c proc: nommu: /proc/<pid>/maps: release mmap read lock 2023-10-06 13:18:22 +02:00
thread_self.c
uptime.c fs/proc/uptime.c: Fix idle time reporting in /proc/uptime 2021-11-18 19:16:13 +01:00
util.c
version.c
vmcore.c fs/proc: fix softlockup in __read_vmcore 2024-07-05 09:14:21 +02:00