[LTP] [PATCH v3 05/11] Add landlock01 test
Li Wang
liwang@redhat.com
Fri Jul 12 04:11:07 CEST 2024
Hi Petr,
On Fri, Jul 12, 2024 at 4:40 AM Petr Vorel <pvorel@suse.cz> wrote:
> Hi Andrea,
>
> again, LGTM, 2 things:
>
> First, this fails at least on various kernel versions (tested: Tumbleweed
> 6.10.0-rc7-3.g92abc10-default, and SLE15-SP4 5.14.21 with lsm=landlock and
> Debian 6.6.15-amd64):
>
> landlock01.c:49: TFAIL: Size is too small expected EINVAL: ENOMSG (42)
>
> Is it a kernel bug or a test bug?
>
You probably need to check the `/usr/include/linux/landlock.h` header file
exist,
and to see if 'struct landlock_ruleset_attr' contains the new field
'handled_access_net'.
If not exist or does not contain that, the test defines 'struct
landlock_ruleset_attr'
in lapi/landlock.h which contains handled_access_net directly, this is
likely the
root cause lead test failed on your box.
>
> I'm not sure if Li's concern [1] was fully addressed:
>
> We still have to adjust the case if someone introduces one more
> new field
> similar to 'handled_access_net' to the structure in the future.
>
> Kind regards,
> Petr
>
> [1]
> https://lore.kernel.org/ltp/CAEemH2dkKvthbx+za-rwfsmanraZuud-sq1O4FZK2zta5MBMSg@mail.gmail.com/
>
>
--
Regards,
Li Wang
More information about the ltp
mailing list