Received: by 10.192.165.156 with SMTP id m28csp1169311imm; Wed, 11 Apr 2018 13:47:46 -0700 (PDT) X-Google-Smtp-Source: AIpwx4+odGUlz1crX4XLYbCLRhkE88W2HHyrpkgjV6HZ1891PTu29rawbUOhGpOoi/wq7XkMwDRi X-Received: by 10.98.245.7 with SMTP id n7mr5268828pfh.164.1523479665964; Wed, 11 Apr 2018 13:47:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1523479665; cv=none; d=google.com; s=arc-20160816; b=A+IDNNBYU5WBbex4gfKTyjbIk0/6IGXh93ItWnj7CeFof6QNNwR2ZSGcNncq2xNNu+ eWJJ8gbx24xHCIdZmgFcMrkrCAKjdBBgyWQXRIWFHjp6suwjhJRSmE9XdakFkJHsSXXK aPh5aL4mm14S7WtJgDEPF1T3ihs+0r/ujxIb9/PTeYhk5qlIz7x3xooruZXCc9aue0iK kNl3k0iAsXbtIDqtrFNo0SQO1uBzYnkB4ngmFjeOmiXX07Yoq1EqhA9b5c/F6pkdqZbv MUhoQJNA/l22W9v7ev91BvRSnEhx4HiLGLTHq0spnBXcrU7nTPn+CSuYhxeUKQ9tqt6C rRaw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature:arc-authentication-results; bh=9xWJlQLO6v43JzuFRfcCdGRhrJo2vDDu58Cut4sqV/Y=; b=hRRw49zMQDlFsYicOno8fBgPUWjqM38aQfEQO5WjJvg/vEwLQQ6nIkM1UminG97GfN N+kuK8VjCidHGs9XEdHyn6G4EpGQ9gktLldJNcYhmYYscsRbGdMcqaJm/SM7x0jAWCAB ZdL+a6skHfmdRRZu63EvV6KwGw0D/Y2bZTZ3qWgNTM9ZOLIPKdgFsYXCGGWjMK/8ILDu Z2MJ7WVA1sFhTqiiw77/x454xPG7Yb95WS1H1EfbR2fDG9vrugSdFY+YCBzQvJ6n3+C7 KcPdbXnX1mNLLNxf3eO7TS8p8Ej+L5cG+9wgpTzpD+oqeliDk8jkgERXMX+Nx2EhFukB JiNw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@messagingengine.com header.s=fm2 header.b=SW2KPwdR; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f14si1206257pgn.597.2018.04.11.13.47.09; Wed, 11 Apr 2018 13:47:45 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@messagingengine.com header.s=fm2 header.b=SW2KPwdR; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932463AbeDKUnS (ORCPT + 99 others); Wed, 11 Apr 2018 16:43:18 -0400 Received: from out3-smtp.messagingengine.com ([66.111.4.27]:54667 "EHLO out3-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932425AbeDKUnP (ORCPT ); Wed, 11 Apr 2018 16:43:15 -0400 X-Greylist: delayed 598 seconds by postgrey-1.27 at vger.kernel.org; Wed, 11 Apr 2018 16:43:14 EDT Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id 06B2120A54; Wed, 11 Apr 2018 16:33:16 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute6.internal (MEProxy); Wed, 11 Apr 2018 16:33:16 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm2; bh=9xWJlQLO6v43JzuFRfcCdGRhrJo2v DDu58Cut4sqV/Y=; b=SW2KPwdRZ8EbSr6l8KfomLcBg/OV09jp6hEjGdX0Qp4EX zuo+YgxCfYoRVS+cBYuh5KGcfoNVzJ85Nzk+wgdQ7TV1OQ3GglJNN+SZ3ZzzlYPE 9kH5uoF3MD3tehGKstS0owmEtaLZDz+KVQYnx64gL31wK17fN6MN+NjmNK1CeGJS R0tPvV5KqCQKWRXp072H/he0tVh8SFcHm4KMouz/I0is7Mh79JVObLNyAcSfXlbK G43Vp/dzmCljkAtH3bdGDrPqV72s/s7S38wAK4lUbOMowRHnkdAk3n8h8tO/K34T 4y5t4TO41nao0+rF+UwZrm1gVQyO86V96ikNAc04Q== X-ME-Sender: Received: from localhost (lfbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) by mail.messagingengine.com (Postfix) with ESMTPA id 529BCE5087; Wed, 11 Apr 2018 16:33:15 -0400 (EDT) Date: Wed, 11 Apr 2018 22:33:08 +0200 From: Greg KH To: David Howells Cc: torvalds@linux-foundation.org, linux-man@vger.kernel.org, linux-api@vger.kernel.org, jmorris@namei.org, linux-kernel@vger.kernel.org, linux-security-module@vger.kernel.org Subject: Re: [PATCH 24/24] debugfs: Restrict debugfs when the kernel is locked down Message-ID: <20180411203308.GA10167@kroah.com> References: <20180411195436.GA7126@kroah.com> <152346387861.4030.4408662483445703127.stgit@warthog.procyon.org.uk> <152346403637.4030.15247096217928429102.stgit@warthog.procyon.org.uk> <12769.1523477356@warthog.procyon.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <12769.1523477356@warthog.procyon.org.uk> User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Apr 11, 2018 at 09:09:16PM +0100, David Howells wrote: > Greg KH wrote: > > > Why not just disable debugfs entirely? This half-hearted way to sorta > > lock it down is odd, it is meant to not be there at all, nothing in your > > normal system should ever depend on it. > > > > So again just don't allow it to be mounted at all, much simpler and more > > obvious as to what is going on. > > Yeah, I agree - and then I got complaints because it seems that it's been > abused to allow drivers and userspace components to communicate. With in-kernel code? Please let me know and I'll go fix it up to not allow that, as that is not ok. I do know of some bad examples of out-of-tree code abusing debugfs to do crazy things (battery level monitoring?), but that's their own fault... debugfs is for DEBUGGING! For anything you all feel should be "secure", then just disable it entirely. thanks, greg k-h