linux-stable/fs/proc
Krister Johansen f95e9f7afe proc: sysctl: prevent aliased sysctls from getting passed to init
commit 8001f49394 upstream.

The code that checks for unknown boot options is unaware of the sysctl
alias facility, which maps bootparams to sysctl values.  If a user sets
an old value that has a valid alias, a message about an invalid
parameter will be printed during boot, and the parameter will get passed
to init.  Fix by checking for the existence of aliased parameters in the
unknown boot parameter code.  If an alias exists, don't return an error
or pass the value to init.

Signed-off-by: Krister Johansen <kjlx@templeofstupid.com>
Cc: stable@vger.kernel.org
Fixes: 0a477e1ae2 ("kernel/sysctl: support handling command line aliases")
Signed-off-by: Luis Chamberlain <mcgrof@kernel.org>
Signed-off-by: Krister Johansen <kjlx@templeofstupid.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-12-03 07:31:24 +01:00
..
array.c
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
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 proc: sysctl: prevent aliased sysctls from getting passed to init 2023-12-03 07:31:24 +01:00
proc_tty.c
root.c
self.c
softirqs.c
stat.c
task_mmu.c mm: hugetlb: proc: check for hugetlb shared PMD in /proc/PID/smaps 2023-02-09 11:26:44 +01: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
util.c
version.c
vmcore.c proc/vmcore: fix clearing user buffer by properly using clear_user() 2021-12-01 09:04:44 +01:00