ltp.lists.linux.it archive mirror
 help / color / mirror / Atom feed
From: Nikolaus Voss <nv@vosn.de>
To: Petr Vorel <pvorel@suse.cz>
Cc: Jarkko Sakkinen <jarkko@kernel.org>,
	ltp@lists.linux.it, Yael Tzur <yaelt@google.com>
Subject: Re: [LTP] [PATCH] syscalls/keyctl/keyctl09.c: fix test encrypted key
Date: Wed, 12 Oct 2022 17:17:58 +0200 (CEST)	[thread overview]
Message-ID: <d2d2afa4-b031-3455-38dd-c099715319e4@vosn.de> (raw)
In-Reply-To: <Y0bUjRsFJLXsAcgL@pevik>

On Wed, 12 Oct 2022, Petr Vorel wrote:
> Hi all,
>
>> Hi!
>>>> This commit fixes the test for adding encrypted keys with unencrypted data.
>>>> Unencryted data must be provided hex-ascii encoding. Due to a kernel
>>>> bug, the unencypted data was not decoded to binary thus the length of
>>>> the key was only half the specified key size. This patch doubles the key
>>>> size and adds a test with a wrong key size to trigger a corresponding
>>>> error.
>
>>>> This patch must be used with the kernel fix
>>>> https://lore.kernel.org/lkml/20220919072317.E41421357@mail.steuer-voss.de
>
>>> Petr, please correct me if I'm wrong.  Changing an existing LTP test so
>>> that it only works on kernels with the kernel patch applied, doesn't
>>> sound right.  The test should emit a warning if the original "valid
>>> payload" successfully loads.
>
>> We also have a policy not to work around any kernel bugs. So if this
>> really fixes a kernel bug it's okay that the test will fail on older
>> kernels without this fix and the patch that fixes kernel should be added
>> as a tag to the test.
>
> @Nikolaus, FYI:
> https://github.com/linux-test-project/ltp/wiki/C-Test-API#138-test-tags
>
> But the patchset has not been even accepted by kernel maintainer - searching in
> the kernel thread, looking into
> https://git.kernel.org/pub/scm/linux/kernel/git/pcmoore/lsm.git/
> and to the next tree.
> Or am I wrong and it has been accepted?
>
> Even once (if ever) the patch is accepted I agree with Mimi it'd be better to
> add new test than change existing old (better for diagnostic what exactly went
> wrong).

ok, thanks, I will change the test and repost when the kernel patch has 
been accepted!

Niko


-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

      reply	other threads:[~2022-10-12 15:18 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-06  6:15 [LTP] [PATCH] syscalls/keyctl/keyctl09.c: fix test encrypted key Nikolaus Voss
2022-10-12 12:48 ` Mimi Zohar
2022-10-12 13:31   ` Cyril Hrubis
2022-10-12 14:51     ` Petr Vorel
2022-10-12 15:17       ` Nikolaus Voss [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=d2d2afa4-b031-3455-38dd-c099715319e4@vosn.de \
    --to=nv@vosn.de \
    --cc=jarkko@kernel.org \
    --cc=ltp@lists.linux.it \
    --cc=pvorel@suse.cz \
    --cc=yaelt@google.com \
    /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;
as well as URLs for NNTP newsgroup(s).