From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751557AbdEIILb (ORCPT ); Tue, 9 May 2017 04:11:31 -0400 Received: from mx1.redhat.com ([209.132.183.28]:33074 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750904AbdEIIL1 (ORCPT ); Tue, 9 May 2017 04:11:27 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 9C9D3624AB Authentication-Results: ext-mx10.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx10.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=dhowells@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 9C9D3624AB Organization: Red Hat UK Ltd. Registered Address: Red Hat UK Ltd, Amberley Place, 107-111 Peascod Street, Windsor, Berkshire, SI4 1TE, United Kingdom. Registered in England and Wales under Company Registration No. 3798903 From: David Howells In-Reply-To: References: <20170508214324.GA124468@beast> <10235.1494280856@warthog.procyon.org.uk> To: Kees Cook Cc: dhowells@redhat.com, James Morris , "Serge E. Hallyn" , keyrings@vger.kernel.org, linux-security-module , LKML Subject: Re: [PATCH] key: Convert big_key payload.data to struct MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <14828.1494317484.1@warthog.procyon.org.uk> Date: Tue, 09 May 2017 09:11:24 +0100 Message-ID: <14829.1494317484@warthog.procyon.org.uk> X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Tue, 09 May 2017 08:11:26 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Kees Cook wrote: > This doesn't protect you against changes in struct path size, > though... the existing code (and this proposal) will break if that > ever happens... True - in which case you should kmalloc() it as Eric suggests. > What's the problem with defining the types at the top level? That > seems like a nice place to see them all at once. It means adding a bunch of dependencies to linux/key.h and union key_payload. Have you considered why we don't just put all the definitions for all the filesystems in linux/fs.h? By this logic it would seem like a nice place to see them all at once. David