On Sun, Apr 10, 2022 at 11:49:09PM +0800, Eryu Guan wrote: > On Wed, Apr 06, 2022 at 11:26:21PM -0700, Eric Biggers wrote: > > From: Eric Biggers <ebiggers@xxxxxxxxxx> > > > > Make the encryption tests create and use a named keyring "xfstests" in > > the session keyring that the tests happen to be running under, rather > > than replace the session keyring using 'keyctl new_session'. > > Unfortunately, the latter doesn't work when the session keyring is owned > > by a non-root user, which (depending on the Linux distro) can happen if > > xfstests is run in a sudo "session" rather than in a real root session. > > > > This isn't a great solution, as the lifetime of the keyring will no > > longer be tied to the tests as it should be, but it should work. The > > alternative would be the weird hack of making the 'check' script > > re-execute itself using something like 'keyctl session - $0 $@'. > > > > Reported-by: Ritesh Harjani <ritesh.list@xxxxxxxxx> > > Signed-off-by: Eric Biggers <ebiggers@xxxxxxxxxx> > > This patch conflicts with patch "common/encrypt: allow the use of > 'fscrypt:' as key prefix", which has been applied in my local tree. > Would you please rebase & resend this one? > Done: https://lore.kernel.org/r/20220414071932.166090-1-ebiggers@xxxxxxxxxx Ritesh, can you verify that this actually fixes the problem for you? - Eric