From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933834AbcDLQy4 (ORCPT ); Tue, 12 Apr 2016 12:54:56 -0400 Received: from mail-pf0-f181.google.com ([209.85.192.181]:34385 "EHLO mail-pf0-f181.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757231AbcDLQyw (ORCPT ); Tue, 12 Apr 2016 12:54:52 -0400 From: Kees Cook To: James Morris Cc: Kees Cook , Joe Perches , Mimi Zohar , Andy Shevchenko , Andrew Morton , "Serge E. Hallyn" , Jonathan Corbet , Kalle Valo , Mauro Carvalho Chehab , Guenter Roeck , Jiri Slaby , Paul Moore , Stephen Smalley , Casey Schaufler , Andreas Gruenbacher , Rasmus Villemoes , Ulf Hansson , Vitaly Kuznetsov , linux-security-module@vger.kernel.org, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org Subject: [PATCH v4 0/6] LSM: LoadPin for kernel file loading restrictions Date: Tue, 12 Apr 2016 09:54:39 -0700 Message-Id: <1460480085-32263-1-git-send-email-keescook@chromium.org> X-Mailer: git-send-email 2.6.3 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This provides the mini-LSM "loadpin" that intercepts the now consolidated kernel_file_read LSM hook so that a system can keep all loads coming from a single trusted filesystem. This is what Chrome OS uses to pin kernel module and firmware loading to the read-only crypto-verified dm-verity partition so that kernel module signing is not needed. -Kees v4: - add missing "const" to char * src, joe v3: - changed module parameter to "loadpin.enabled" - add sysctl docs, akpm - add general use function for enum, zohar - add gfp_t, joe - clean up loops, andriy.shevchenko - reduce BUG_ON to WARN_ON, joe v2: - break out utility helpers into separate functions - have Yama use new helpers too