Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp15469516rwd; Sun, 25 Jun 2023 18:29:13 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ635mcEVCUTc6b5No0rOUb/8jNseJ+5WDA3X6+U8FHtrxGMzVxnq36FNjQVC5tbGC8Uf+7+ X-Received: by 2002:a92:ce02:0:b0:341:fdd4:9acb with SMTP id b2-20020a92ce02000000b00341fdd49acbmr17959480ilo.14.1687742953172; Sun, 25 Jun 2023 18:29:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687742953; cv=none; d=google.com; s=arc-20160816; b=Z9uG+taFFxr3MoyKMF0wzUC36Fq0DgXbT+XOin03etNcb8L8rSXBiqUrs4Xn2ZLTnl ScoZOjzjptDkKqCbjhzC5nL/uqrH/FaXrKHLLF9Pi1LYgca5PIdgwPjiPBiGRyhPHsdh JpwVFqQth3b8WrlMDmOu1ORgPznzohLZA2bJ5TsuYHl6I0y1ZIp+L+anHzJo/W+Vd9Zy hWqhn4sudkRiIYAqx1dSuQzRwuRNjN3SYjKyq5CSF8yTVW3IdfVKNTFhrOODvIUxQqIK /LDojcyBWksDvsvUknzfNWJPxOKvree2OUcqyQicnLJRHDSvOpsRaZHBXHa1hpCrozL2 Yeow== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=HnPIjne0x1y1DoyjPxRNCutxaRJPDQqxcvlLV/KyJEA=; fh=cInLN82Pj4hl1FmaW52MkVs0JK3Ra1pu/h8506goSk4=; b=NULxNYa4KyZcHjnKlfZ5iPbKHG9jV+UGrWX29X36f2DYCUhc+nOL0/ov1xsiW5W94D XicXYJXOW8Zxdbwpl1vKDx64+yFet7DKiUJ1a4P5jbrFGPGeiXlYQ95agAltvwY90Hoc nj6vNtvoZNy1qiZ4KV1b33uhou6rcLIQIq1GP7s6YCi/K+iVLVZnKapRDJuTSDnrOO+5 Yrp5tkC9UI4SeCtZWv2hB/cNC/uosq/2BAm/xM/ZHtLtsOy9rYcS+8Es8E/aSXWzZDlG fKt0xfpoWBXU8QiLGvjsZWGY7cWfJ+ojSysqtz0aS/Wu/ObM17TDAjapLpXRhfIcLHz3 RH+A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=RAUtQMnp; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-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 j23-20020a63ec17000000b00543bfe3eaffsi3946209pgh.762.2023.06.25.18.29.01; Sun, 25 Jun 2023 18:29:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-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=RAUtQMnp; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-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 S229701AbjFZBFJ (ORCPT + 99 others); Sun, 25 Jun 2023 21:05:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49810 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229905AbjFZBFB (ORCPT ); Sun, 25 Jun 2023 21:05:01 -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 831A118F for ; Sun, 25 Jun 2023 18:04:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1687741455; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=HnPIjne0x1y1DoyjPxRNCutxaRJPDQqxcvlLV/KyJEA=; b=RAUtQMnpV8fiEtk9m4SnvxlxSE021Nr29HVDwHV9DePpvp+PLhrnjx5SCPbuc0Yxjk79Xk CFc5uCEOZrhh/rGfl30k75LQxDDJcLNTWmibgHHHPoz3sOo5Odl1Djar5Cilhblr6rWGIA l+OQS4DUsJWyb755VE4eAokqiijVJSI= Received: from mail-qt1-f197.google.com (mail-qt1-f197.google.com [209.85.160.197]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-310-RwTkZ2mGO82lSQJp_-ETOg-1; Sun, 25 Jun 2023 21:04:12 -0400 X-MC-Unique: RwTkZ2mGO82lSQJp_-ETOg-1 Received: by mail-qt1-f197.google.com with SMTP id d75a77b69052e-4007ea5af13so42248091cf.1 for ; Sun, 25 Jun 2023 18:04:12 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687741452; x=1690333452; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=HnPIjne0x1y1DoyjPxRNCutxaRJPDQqxcvlLV/KyJEA=; b=WFM3HeFCnxthrW4Q+24VsZq9KJg90bWBBeLH3opCXUOZ7BR7FlylyjmWii8H7zxraL vyr3omlcx5GGvdvQUIV8PYJwedpuQ1pR6tLB3O5Qy0f0pmiOicaMZBqs83J8qpUJ/vsw qvNsuC1+mtRAnLkpALZpItDN6q2vfyokLLZJL3dj8Q2eltpMQ1w5nVny9Yp+0Klcals1 s86XQYTwSbzO/tL+mqrBLtECrvqMH2n9tyd2q6Uo6gtSJtE3Uao5m4YYmO2/z4LXaLVT IuQEhD+OByjiYffQ+NSKEO0tQfAAy0EFV2DgnSlorZWZ7gTgQbOgmKpTntmlJTUoiEfC 2A6w== X-Gm-Message-State: AC+VfDwBB9rN+/A44Sn0CzEn6mIGHJtFtM8pGmyu3hN21PkAAbGBgZvT hvo6egACjsSSBWdu2pXAf6oF6Ccg/0+o4NTansTXpuIHUEtpqsQ1JGCMVnMkJ718kLJjCe6yyeT 2HJ/D1q3GWdD2dTig1k1LlI2H X-Received: by 2002:a05:622a:1746:b0:3ff:3013:d2aa with SMTP id l6-20020a05622a174600b003ff3013d2aamr23516662qtk.12.1687741451950; Sun, 25 Jun 2023 18:04:11 -0700 (PDT) X-Received: by 2002:a05:622a:1746:b0:3ff:3013:d2aa with SMTP id l6-20020a05622a174600b003ff3013d2aamr23516640qtk.12.1687741451626; Sun, 25 Jun 2023 18:04:11 -0700 (PDT) Received: from [10.72.13.91] ([43.228.180.230]) by smtp.gmail.com with ESMTPSA id d26-20020aa7869a000000b0063d2dae6247sm776415pfo.77.2023.06.25.18.04.06 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 25 Jun 2023 18:04:11 -0700 (PDT) Message-ID: <07b01202-9c38-70a7-8701-be8992a1d17e@redhat.com> Date: Mon, 26 Jun 2023 09:04:04 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0 Subject: Re: [PATCH v5 00/14] ceph: support idmapped mounts Content-Language: en-US To: Aleksandr Mikhalitsyn Cc: Gregory Farnum , Christian Brauner , stgraber@ubuntu.com, linux-fsdevel@vger.kernel.org, Ilya Dryomov , Jeff Layton , ceph-devel@vger.kernel.org, linux-kernel@vger.kernel.org References: <20230608154256.562906-1-aleksandr.mikhalitsyn@canonical.com> <20230609-alufolie-gezaubert-f18ef17cda12@brauner> <977d8133-a55f-0667-dc12-aa6fd7d8c3e4@redhat.com> <626175e2-ee91-0f1a-9e5d-e506aea366fa@redhat.com> From: Xiubo Li In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-3.2 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE, SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable 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-kernel@vger.kernel.org On 6/15/23 20:54, Aleksandr Mikhalitsyn wrote: > On Thu, Jun 15, 2023 at 2:29 PM Xiubo Li wrote: >> [...] >> >> > > > >> > > > I thought about this too and came to the same conclusion, that >> UID/GID >> > > > based >> > > > restriction can be applied dynamically, so detecting it on mount-time >> > > > helps not so much. >> > > > >> > > For this you please raise one PR to ceph first to support this, and in >> > > the PR we can discuss more for the MDS auth caps. And after the PR >> > > getting merged then in this patch series you need to check the >> > > corresponding option or flag to determine whether could the idmap >> > > mounting succeed. >> > >> > I'm sorry but I don't understand what we want to support here. Do we >> want to >> > add some new ceph request that allows to check if UID/GID-based >> > permissions are applied for >> > a particular ceph client user? >> >> IMO we should prevent users to set UID/GID-based MDS auth caps from ceph >> side. And users should know what has happened. > ok, we want to restrict setting of UID/GID-based permissions if there is an > idmapped mount on the client. IMHO, idmapping mounts is truly a > client-side feature > and server modification looks a bit strange to me. Yeah, agree. But without fixing the lookup issue in kclient side it will be buggy and may make some tests fail too. We need to support this more smoothly. Thanks - Xiubo >> Once users want to support the idmap mounts they should know that the >> MDS auth caps won't work anymore. > They will work, but permission rule configuration should include > non-mapped UID/GID-s. > As I mentioned here [1] it's already the case even without mount idmappings. > > It would be great to discuss this thing as a concept and synchronize > our understanding of this > before going into modification of a server side. > > [1] https://lore.kernel.org/lkml/CAEivzxcBBJV6DOGzy5S7=TUjrXZfVaGaJX5z7WFzYq1w4MdtiA@mail.gmail.com/ > > Kind regards, > Alex > >> Thanks >> >> - Xiubo >>