[PATCH v5 2/4] selftests/landlock: Selftests for file truncation support
Mickaël Salaün
mic at digikod.net
Fri Aug 19 08:15:24 UTC 2022
Ok, it should be in -next soon. Thanks for your contribution!
Would you like to write a syzkaller test to cover this new access right?
You only need to update the landlock_fs_accesses file with a call to
truncate() returning EACCES and check that it covers
hook_path_truncate(). You can take inspiration from this PR:
https://github.com/google/syzkaller/pull/3133
Please CC me, I can help.
Regards,
Mickaël
On 19/08/2022 07:24, Günther Noack wrote:
> On Thu, Aug 18, 2022 at 10:39:27PM +0200, Mickaël Salaün wrote:
>> On 17/08/2022 22:30, Günther Noack wrote:
>>> +/*
>>> + * Invokes creat(2) and returns its errno or 0.
>>> + * Closes the opened file descriptor on success.
>>> + */
>>> +static int test_creat(const char *const path, mode_t mode)
>>
>> This "mode" argument is always 0600. If it's OK with you, I hard code this
>> mode and push this series to -next with some small cosmetic fixes.
>
> Yes, absolutely. Please do these fixes and push it to -next. :)
>
> Thanks,
> —Günther
>
> --
More information about the Linux-security-module-archive
mailing list