lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1489080561-30786-1-git-send-email-tycho@docker.com>
Date:   Thu,  9 Mar 2017 09:29:21 -0800
From:   Tycho Andersen <tycho@...ker.com>
To:     Kees Cook <keescook@...omium.org>,
        James Morris <james.l.morris@...cle.com>
Cc:     linux-security-module@...r.kernel.org,
        linux-kernel@...r.kernel.org, Tycho Andersen <tycho@...ker.com>,
        "Serge E. Hallyn" <serge@...lyn.com>
Subject: [PATCH] security/Kconfig: further restrict HARDENED_USERCOPY

It doesn't make sense to have HARDENED_USERCOPY when either /dev/kmem is
enabled or /dev/mem can be used to read kernel memory.

v2: add !MMU depend as well

Signed-off-by: Tycho Andersen <tycho@...ker.com>
CC: Kees Cook <keescook@...omium.org>
CC: "Serge E. Hallyn" <serge@...lyn.com>
CC: James Morris <james.l.morris@...cle.com>
---
 security/Kconfig | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/security/Kconfig b/security/Kconfig
index 3ff1bf9..aeabd40 100644
--- a/security/Kconfig
+++ b/security/Kconfig
@@ -142,6 +142,8 @@ config HARDENED_USERCOPY
 	bool "Harden memory copies between kernel and userspace"
 	depends on HAVE_ARCH_HARDENED_USERCOPY
 	depends on HAVE_HARDENED_USERCOPY_ALLOCATOR
+	depends on !DEVKMEM
+	depends on !ARCH_HAS_DEVMEM_IS_ALLOWED || STRICT_DEVMEM || !MMU
 	select BUG
 	help
 	  This option checks for obviously wrong memory regions when
-- 
2.7.4

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ