Skip to content

Backport v6.2 SGID fixes to LTS 6.1

Amir Goldstein linux-fsdevel stable 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest5 patches 1 replyIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5attr: add in_group_or_capable()fs/attr.c fs/inode.c fs/internal.h+31 -90 replies
2/5fs: move should_remove_suid()fs/attr.c fs/inode.c+29 -290 replies
3/5attr: add setattr_should_drop_sgid()fs/attr.c fs/internal.h+34 -00 replies
4/5attr: use consistent sgid stripping checksDocumentation/trace/ftrace.rst fs/attr.c fs/fuse/file.c +5 more+33 -270 replies
5/5fs: use consistent setgid checks in is_sxid()include/linux/fs.h+1 -10 replies

Reviews trailers per patch

4 of 5 patches have a Reviewed-by or Acked-by.

PatchAmir Goldstein
1/5R-b
2/5R-b
3/5R-b
4/5R-b
5/5

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 6.1 0/5] Backport v6.2 SGID fixes to LTS 6.1

Greg,

Following are backports of Christian's SGID fixes that were merged to v6.2-rc1.

Note that Christain's PR [1] contains also two ovl patches (from me). Those two are independent fixes that have already been AUTOSELected to 6.1.y.

Christain's fixes also contain a user observable change of behavior to fix inconsistencies of behavior between chmod/chown and write. This change is best described in Christain's commit to fix the expected behavior in xfstests [2].

It is hoped that no applications rely on this minor behavioral difference, and if we are wrong, we may need to party revert the change, but in any case, we prefer the behavior of LTS kernels to be consitent with that of upstream.

I ran the relevant fstests test groups on xfs and on overlayfs over xfs.

I also have backports that I prepared for 5.15 and 5.10, but those backports include also xfs SGID fixes, so those need to go through the xfs stable review process.

Thanks,
Amir.

[1] https://lore.kernel.org/linux-fsdevel/[email protected]/
[2] https://lore.kernel.org/linux-fsdevel/[email protected]/

Christian Brauner (5):
attr: add in_group_or_capable()
fs: move should_remove_suid()
attr: add setattr_should_drop_sgid()
attr: use consistent sgid stripping checks
fs: use consistent setgid checks in is_sxid()

 Documentation/trace/ftrace.rst |  2 +-
 fs/attr.c                      | 74 +++++++++++++++++++++++++++++++---
 fs/fuse/file.c                 |  2 +-
 fs/inode.c                     | 64 +++++++++++++----------------
 fs/internal.h                  | 10 ++++-
 fs/ocfs2/file.c                |  4 +-
 fs/open.c                      |  8 ++--
 include/linux/fs.h             |  4 +-
 8 files changed, 115 insertions(+), 53 deletions(-)
Signature · 1 line
2.34.1