From mboxrd@z Thu Jan 1 00:00:00 1970 From: Peter =?utf-8?q?M=C3=BCller?= To: development@lists.ipfire.org Subject: [PATCH] linux: Disable cachestat() system call Date: Sun, 22 Sep 2024 18:01:45 +0000 Message-ID: <20240922180145.835402-1-peter.mueller@ipfire.org> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============6919083165094329212==" List-Id: --===============6919083165094329212== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable >>From the kernel's documentation: > Enable the cachestat system call, which queries the page > cache statistics of a file (number of cached pages, dirty > pages, pages marked for writeback, (recently) evicted pages). There is no legitimate use-case for this feature in IPFire, and grsecurity recommends disabling it to cut attack surface. Signed-off-by: Peter M=C3=BCller --- config/kernel/kernel.config.aarch64-ipfire | 2 +- config/kernel/kernel.config.riscv64-ipfire | 2 +- config/kernel/kernel.config.x86_64-ipfire | 2 +- config/rootfiles/common/aarch64/linux | 1 - config/rootfiles/common/riscv64/linux | 1 - config/rootfiles/common/x86_64/linux | 1 - 6 files changed, 3 insertions(+), 6 deletions(-) diff --git a/config/kernel/kernel.config.aarch64-ipfire b/config/kernel/kerne= l.config.aarch64-ipfire index 74085de00..b2753cdbf 100644 --- a/config/kernel/kernel.config.aarch64-ipfire +++ b/config/kernel/kernel.config.aarch64-ipfire @@ -243,7 +243,7 @@ CONFIG_KALLSYMS_BASE_RELATIVE=3Dy CONFIG_ARCH_HAS_MEMBARRIER_SYNC_CORE=3Dy CONFIG_KCMP=3Dy CONFIG_RSEQ=3Dy -CONFIG_CACHESTAT_SYSCALL=3Dy +# CONFIG_CACHESTAT_SYSCALL is not set # CONFIG_DEBUG_RSEQ is not set CONFIG_HAVE_PERF_EVENTS=3Dy CONFIG_GUEST_PERF_EVENTS=3Dy diff --git a/config/kernel/kernel.config.riscv64-ipfire b/config/kernel/kerne= l.config.riscv64-ipfire index 451607c17..77487de34 100644 --- a/config/kernel/kernel.config.riscv64-ipfire +++ b/config/kernel/kernel.config.riscv64-ipfire @@ -245,7 +245,7 @@ CONFIG_KALLSYMS_ALL=3Dy CONFIG_KALLSYMS_BASE_RELATIVE=3Dy CONFIG_KCMP=3Dy CONFIG_RSEQ=3Dy -CONFIG_CACHESTAT_SYSCALL=3Dy +# CONFIG_CACHESTAT_SYSCALL is not set # CONFIG_DEBUG_RSEQ is not set CONFIG_HAVE_PERF_EVENTS=3Dy # CONFIG_PC104 is not set diff --git a/config/kernel/kernel.config.x86_64-ipfire b/config/kernel/kernel= .config.x86_64-ipfire index 6f0f1bfa5..c17757421 100644 --- a/config/kernel/kernel.config.x86_64-ipfire +++ b/config/kernel/kernel.config.x86_64-ipfire @@ -264,7 +264,7 @@ CONFIG_KALLSYMS_BASE_RELATIVE=3Dy CONFIG_ARCH_HAS_MEMBARRIER_SYNC_CORE=3Dy CONFIG_KCMP=3Dy CONFIG_RSEQ=3Dy -CONFIG_CACHESTAT_SYSCALL=3Dy +# CONFIG_CACHESTAT_SYSCALL is not set # CONFIG_DEBUG_RSEQ is not set CONFIG_HAVE_PERF_EVENTS=3Dy CONFIG_GUEST_PERF_EVENTS=3Dy diff --git a/config/rootfiles/common/aarch64/linux b/config/rootfiles/common/= aarch64/linux index 53dedd2f3..98eee80a7 100644 --- a/config/rootfiles/common/aarch64/linux +++ b/config/rootfiles/common/aarch64/linux @@ -7608,7 +7608,6 @@ etc/modprobe.d/ipv6.conf #lib/modules/KVER/build/include/config/BUILD_SALT #lib/modules/KVER/build/include/config/BUILTIN_RETURN_ADDRESS_STRIPS_PAC #lib/modules/KVER/build/include/config/CACHEFILES -#lib/modules/KVER/build/include/config/CACHESTAT_SYSCALL #lib/modules/KVER/build/include/config/CARL9170 #lib/modules/KVER/build/include/config/CARL9170_HWRNG #lib/modules/KVER/build/include/config/CARL9170_LEDS diff --git a/config/rootfiles/common/riscv64/linux b/config/rootfiles/common/= riscv64/linux index dca2c7370..626238714 100644 --- a/config/rootfiles/common/riscv64/linux +++ b/config/rootfiles/common/riscv64/linux @@ -6940,7 +6940,6 @@ etc/modprobe.d/ipv6.conf #lib/modules/KVER/build/include/config/BUILDTIME_TABLE_SORT #lib/modules/KVER/build/include/config/BUILD_SALT #lib/modules/KVER/build/include/config/CACHEFILES -#lib/modules/KVER/build/include/config/CACHESTAT_SYSCALL #lib/modules/KVER/build/include/config/CADENCE_WATCHDOG #lib/modules/KVER/build/include/config/CARDBUS #lib/modules/KVER/build/include/config/CARL9170 diff --git a/config/rootfiles/common/x86_64/linux b/config/rootfiles/common/x= 86_64/linux index cecaf36fa..6505e9a54 100644 --- a/config/rootfiles/common/x86_64/linux +++ b/config/rootfiles/common/x86_64/linux @@ -7289,7 +7289,6 @@ etc/modprobe.d/ipv6.conf #lib/modules/KVER/build/include/config/BUILDTIME_TABLE_SORT #lib/modules/KVER/build/include/config/BUILD_SALT #lib/modules/KVER/build/include/config/CACHEFILES -#lib/modules/KVER/build/include/config/CACHESTAT_SYSCALL #lib/modules/KVER/build/include/config/CADENCE_WATCHDOG #lib/modules/KVER/build/include/config/CALL_DEPTH_TRACKING #lib/modules/KVER/build/include/config/CALL_PADDING --=20 2.39.5 --===============6919083165094329212==--