lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAOQ4uxhdnv0H4w=V_FXxpDPsVB5Y9noS=ksqy1=CATJUXLKVfA@mail.gmail.com>
Date: Sun, 24 Nov 2024 18:00:07 +0100
From: Amir Goldstein <amir73il@...il.com>
To: Christian Brauner <brauner@...nel.org>
Cc: Linus Torvalds <torvalds@...ux-foundation.org>, Miklos Szeredi <miklos@...redi.hu>, 
	linux-kernel@...r.kernel.org, linux-fsdevel@...r.kernel.org
Subject: Re: [PATCH 00/26] cred: rework {override,revert}_creds()

On Sun, Nov 24, 2024 at 2:44 PM Christian Brauner <brauner@...nel.org> wrote:
>
> For the v6.13 cycle we switched overlayfs to a variant of
> override_creds() that doesn't take an extra reference. To this end I
> suggested introducing {override,revert}_creds_light() which overlayfs
> could use.
>
> This seems to work rather well. As Linus correctly points out that we
> should look into unifying both and simply make {override,revert}_creds()
> do what {override,revert}_creds_light() currently does. Caller's that
> really need the extra reference count can take it manually.
>
> This series does all that. Afaict, most callers can be directly
> converted over and can avoid the extra reference count completely.
>
> Lightly tested.

FWIW, your work.cred branch passes the overlayfs tests.

Thanks,
Amir.

>
> ---
> Christian Brauner (26):
>       tree-wide: s/override_creds()/override_creds_light(get_new_cred())/g
>       cred: return old creds from revert_creds_light()
>       tree-wide: s/revert_creds()/put_cred(revert_creds_light())/g
>       cred: remove old {override,revert}_creds() helpers
>       tree-wide: s/override_creds_light()/override_creds()/g
>       tree-wide: s/revert_creds_light()/revert_creds()/g
>       firmware: avoid pointless reference count bump
>       sev-dev: avoid pointless cred reference count bump
>       target_core_configfs: avoid pointless cred reference count bump
>       aio: avoid pointless cred reference count bump
>       binfmt_misc: avoid pointless cred reference count bump
>       coredump: avoid pointless cred reference count bump
>       nfs/localio: avoid pointless cred reference count bumps
>       nfs/nfs4idmap: avoid pointless reference count bump
>       nfs/nfs4recover: avoid pointless cred reference count bump
>       nfsfh: avoid pointless cred reference count bump
>       open: avoid pointless cred reference count bump
>       ovl: avoid pointless cred reference count bump
>       cifs: avoid pointless cred reference count bump
>       cifs: avoid pointless cred reference count bump
>       smb: avoid pointless cred reference count bump
>       io_uring: avoid pointless cred reference count bump
>       acct: avoid pointless reference count bump
>       cgroup: avoid pointless cred reference count bump
>       trace: avoid pointless cred reference count bump
>       dns_resolver: avoid pointless cred reference count bump
>
>  drivers/base/firmware_loader/main.c   |  3 +--
>  drivers/crypto/ccp/sev-dev.c          |  2 +-
>  drivers/target/target_core_configfs.c |  3 +--
>  fs/aio.c                              |  3 +--
>  fs/backing-file.c                     | 20 +++++++-------
>  fs/cachefiles/internal.h              |  4 +--
>  fs/nfsd/auth.c                        |  4 +--
>  fs/nfsd/filecache.c                   |  2 +-
>  fs/nfsd/nfs4recover.c                 |  3 +--
>  fs/nfsd/nfsfh.c                       |  1 -
>  fs/open.c                             | 10 ++-----
>  fs/overlayfs/copy_up.c                |  6 ++---
>  fs/overlayfs/dir.c                    |  4 +--
>  fs/overlayfs/util.c                   |  4 +--
>  fs/smb/server/smb_common.c            |  4 +--
>  include/linux/cred.h                  | 14 ++++------
>  kernel/cred.c                         | 50 -----------------------------------
>  kernel/trace/trace_events_user.c      |  3 +--
>  18 files changed, 35 insertions(+), 105 deletions(-)
> ---
> base-commit: 228a1157fb9fec47eb135b51c0202b574e079ebf
> change-id: 20241124-work-cred-349b65450082
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ