Received: by 2002:a05:6358:489b:b0:bb:da1:e618 with SMTP id x27csp1108057rwn; Thu, 8 Sep 2022 13:37:09 -0700 (PDT) X-Google-Smtp-Source: AA6agR58Sfrh2D6s71JBEPznZX2kMki/06z3iASGoUclpCWpInEdqgql7kjjpytIggqvTWPE9oXF X-Received: by 2002:a2e:8802:0:b0:26a:b497:8dfa with SMTP id x2-20020a2e8802000000b0026ab4978dfamr3186044ljh.433.1662669429752; Thu, 08 Sep 2022 13:37:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1662669429; cv=none; d=google.com; s=arc-20160816; b=trKgk3QoRxqSmnyhMHoBw7ORsVockNqntUmMcYmiV/1m0g8uQSUowzHBw+AJvLw6W0 ejvMQGg6YY25QJOsKOtPH+kfGjgZS/BrLDfLuk+7w4+xc97llMEzOJ9GDkF6DdK98oCN Szj96rGOoFKwMqHsgMNz6UFB5kQ3lAQXVaPByiyuvWfcgDbT4IDUSyipiWu6G0yebhVj OSIZGXNJEOHyxpxQc9e0yMkynxdfzsqhOmzq+zSdCpLSOxzMpv8QXpSYt5kmI8MHOMsV ZjArPvcRFKYHgUKuvDombZ/wdP1skv8wM9DJKWA5ydOh2de1S/ibjRbcOSV0K5s+yvuM HHRQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:content-id:mime-version:subject :cc:to:references:in-reply-to:from:organization:dkim-signature; bh=W8xW/PUmCF7EBejEjlfKNcmSxgxp+ng+o6KaVNQoPyk=; b=0bSZi5o7qzAyPCN7sfpay1JRO+No9+6ihGlna7FMcCciMH4SENOWXEHLkYC+YR0rjr w2nz9j1m0Cks8oYs81iXBKPe2+mupgV60wdrBx2xFdSlAeYPlwmqg3oZW980v2pL1/Gv GpQir/MXI2iW35nbe+uuck1tH9GaTeatN2WO0y6Dr+INMnJ8HCex5Z7jRP8BBKtp7z8U hLTn4BHiJx4cbkgrZ5OkcblKJgWPAhTF/We6tY1wrHZCMsTyk2G3+2a+hKh+LiS3ep1W sYJ8cxGwqeS9UorsRgV+3Vrp6iOjwK2s9fmgIZflJK+FlMIuBhWK1f3sDSNitow+Q7TV fEWA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=SBl5+JQx; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x19-20020a0565123f9300b00492dc299b6dsi9258455lfa.105.2022.09.08.13.36.36; Thu, 08 Sep 2022 13:37:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=SBl5+JQx; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229648AbiIHUb3 (ORCPT + 99 others); Thu, 8 Sep 2022 16:31:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45902 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229464AbiIHUb1 (ORCPT ); Thu, 8 Sep 2022 16:31:27 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1543323BC3 for ; Thu, 8 Sep 2022 13:31:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1662669086; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=W8xW/PUmCF7EBejEjlfKNcmSxgxp+ng+o6KaVNQoPyk=; b=SBl5+JQxTpjoud7RhyIIMjlsljCTL51dTKBFEgMkLM1MNhorA5bCLJToO6I7OvsMMUcwxH ZUTd0zIj/LeofyQHd6uM0c89rJkUKd2KyBJGZ4GtsRC/RR1gN2PKDEQC46RAV4cuyAggXT dCLiLVNOJx3OOlW+ZWuVaNKZ/ntZKJc= Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-76-ZBRNITwkPmiBGip5fai_bQ-1; Thu, 08 Sep 2022 16:31:25 -0400 X-MC-Unique: ZBRNITwkPmiBGip5fai_bQ-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 6011529DD9B4; Thu, 8 Sep 2022 20:31:24 +0000 (UTC) Received: from warthog.procyon.org.uk (unknown [10.33.36.11]) by smtp.corp.redhat.com (Postfix) with ESMTP id BB1842166B26; Thu, 8 Sep 2022 20:31:22 +0000 (UTC) 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: <166133579016.3678898.6283195019480567275.stgit@warthog.procyon.org.uk> To: Anna Schumaker Cc: dhowells@redhat.com, Al Viro , Jeff Layton , Trond Myklebust , Scott Mayhew , Paul Moore , Casey Schaufler , Linux NFS Mailing List , SElinux list , Linux Security Module list , linux-fsdevel , David Wysochanski , Linux Kernel Mailing List Subject: Re: [PATCH v4] vfs, security: Fix automount superblock LSM init problem, preventing NFS sb sharing MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <3658627.1662669081.1@warthog.procyon.org.uk> Date: Thu, 08 Sep 2022 21:31:21 +0100 Message-ID: <3658630.1662669081@warthog.procyon.org.uk> X-Scanned-By: MIMEDefang 2.78 on 10.11.54.6 X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org Anna Schumaker wrote: > > + fc->lsm_set = true; > > I was wondering if there is any way to have security_sb_set_mnt_opts() > or security_sb_clone_mnt_opts() set this value automatically? A quick > "git-grep" for security_sb_set_mnt_opts() shows that it's also called > by btrfs at some point, so having this done automatically feels less > fragile to me than requiring individual filesystems to set it > manually. Hmmm... I wonder if cifs and afs should be calling security_sb_clone_mnt_opts() also. David