From 9786eb22a4a7c230768d2c7ebf39c0e09a0bd1e4 Mon Sep 17 00:00:00 2001 From: fanquake Date: Fri, 25 Oct 2024 17:04:18 +0100 Subject: [PATCH] randomenv: remove /proc/ access The data we try and gather in this file is on a best-effort basis, however in this instance, for certain users, it's just producing spam. This could (possibly?) be solved with further snap/apparmor configuration, however given that no-one is actively working on packaging, we could instead drop this (one of many), sources of dynamic environment data. Closes https://github.com/bitcoin-core/packaging/issues/115. --- src/randomenv.cpp | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/src/randomenv.cpp b/src/randomenv.cpp index 7a46a5109bce2..8d1b9e1a32c25 100644 --- a/src/randomenv.cpp +++ b/src/randomenv.cpp @@ -222,18 +222,6 @@ void RandAddDynamicEnv(CSHA512& hasher) if (getrusage(RUSAGE_SELF, &usage) == 0) hasher << usage; #endif -#ifdef __linux__ - AddFile(hasher, "/proc/diskstats"); - AddFile(hasher, "/proc/vmstat"); - AddFile(hasher, "/proc/schedstat"); - AddFile(hasher, "/proc/zoneinfo"); - AddFile(hasher, "/proc/meminfo"); - AddFile(hasher, "/proc/softirqs"); - AddFile(hasher, "/proc/stat"); - AddFile(hasher, "/proc/self/schedstat"); - AddFile(hasher, "/proc/self/status"); -#endif - #ifdef HAVE_SYSCTL # ifdef CTL_KERN # if defined(KERN_PROC) && defined(KERN_PROC_ALL)