From: Christoph Hellwig <hch@infradead.org>
To: "Darrick J. Wong" <djwong@kernel.org>
Cc: sandeen@sandeen.net, Catherine Hoang <catherine.hoang@oracle.com>,
Christoph Hellwig <hch@lst.de>,
linux-xfs@vger.kernel.org
Subject: Re: [PATCH 6/6] mkfs: don't trample the gid set in the protofile
Date: Tue, 10 May 2022 05:55:45 -0700 [thread overview]
Message-ID: <Ynpg0UbWIJsvHKS3@infradead.org> (raw)
In-Reply-To: <165176674260.248587.3749201858763431936.stgit@magnolia>
On Thu, May 05, 2022 at 09:05:42AM -0700, Darrick J. Wong wrote:
> From: Darrick J. Wong <djwong@kernel.org>
>
> Catherine's recent changes to xfs/019 exposed a bug in how libxfs
> handles setgid bits. mkfs reads the desired gid in from the protofile,
> but if the parent directory is setgid, it will override the user's
> setting and (re)set the child's gid to the parent's gid. Overriding
> user settings is (probably) not the desired mode of operation, so create
> a flag to struct cred to force the gid in the protofile.
>
> It looks like this has been broken since ~2005.
Ouch. The fix looks good:
Reviewed-by: Christoph Hellwig <hch@lst.de>
prev parent reply other threads:[~2022-05-10 12:56 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-05 16:05 [PATCHSET 0/6] mkfs: various bug fixes Darrick J. Wong
2022-05-05 16:05 ` [PATCH 1/6] mkfs: fix missing validation of -l size against maximum internal log size Darrick J. Wong
2022-05-05 16:05 ` [PATCH 2/6] mkfs: reduce internal log size when log stripe units are in play Darrick J. Wong
2022-05-05 16:05 ` [PATCH 3/6] mkfs: don't let internal logs bump the root dir inode chunk to AG 1 Darrick J. Wong
2022-05-05 16:05 ` [PATCH 4/6] mkfs: improve log extent validation Darrick J. Wong
2022-05-05 16:05 ` [PATCH 5/6] mkfs: round log size down if rounding log start up causes overflow Darrick J. Wong
2022-05-10 12:55 ` Christoph Hellwig
2022-05-05 16:05 ` [PATCH 6/6] mkfs: don't trample the gid set in the protofile Darrick J. Wong
2022-05-10 12:55 ` Christoph Hellwig [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Ynpg0UbWIJsvHKS3@infradead.org \
--to=hch@infradead.org \
--cc=catherine.hoang@oracle.com \
--cc=djwong@kernel.org \
--cc=hch@lst.de \
--cc=linux-xfs@vger.kernel.org \
--cc=sandeen@sandeen.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox