* [LTP] [PATCH 1/1] delete_module0{1, 3}: Skip when kernel is locked down
@ 2021-06-29 6:58 Petr Vorel
2021-06-29 7:02 ` Petr Vorel
0 siblings, 1 reply; 5+ messages in thread
From: Petr Vorel @ 2021-06-29 6:58 UTC (permalink / raw)
To: ltp
Lockdown requires signed modules, otherwise tests fails with EPERM.
TCONF until we solve signing modules in LTP build.
Signed-off-by: Petr Vorel <pvorel@suse.cz>
---
testcases/kernel/syscalls/delete_module/delete_module01.c | 4 ++++
testcases/kernel/syscalls/delete_module/delete_module03.c | 4 ++++
2 files changed, 8 insertions(+)
diff --git a/testcases/kernel/syscalls/delete_module/delete_module01.c b/testcases/kernel/syscalls/delete_module/delete_module01.c
index 8fb559f0c..cec20c19c 100644
--- a/testcases/kernel/syscalls/delete_module/delete_module01.c
+++ b/testcases/kernel/syscalls/delete_module/delete_module01.c
@@ -25,6 +25,10 @@ static int module_loaded;
static void do_delete_module(void)
{
+ /* lockdown requires signed modules */
+ if (tst_lockdown_enabled())
+ tst_brk(TCONF, "Kernel is locked down, skip this test");
+
if (module_loaded == 0) {
tst_module_load(MODULE_NAME_KO, NULL);
module_loaded = 1;
diff --git a/testcases/kernel/syscalls/delete_module/delete_module03.c b/testcases/kernel/syscalls/delete_module/delete_module03.c
index 7178e8ef1..56cef459f 100644
--- a/testcases/kernel/syscalls/delete_module/delete_module03.c
+++ b/testcases/kernel/syscalls/delete_module/delete_module03.c
@@ -50,6 +50,10 @@ static void do_delete_module(void)
static void setup(void)
{
+ /* lockdown requires signed modules */
+ if (tst_lockdown_enabled())
+ tst_brk(TCONF, "Kernel is locked down, skip this test");
+
/* Load first kernel module */
tst_module_load(DUMMY_MOD_KO, NULL);
dummy_mod_loaded = 1;
--
2.32.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [LTP] [PATCH 1/1] delete_module0{1, 3}: Skip when kernel is locked down
2021-06-29 6:58 [LTP] [PATCH 1/1] delete_module0{1, 3}: Skip when kernel is locked down Petr Vorel
@ 2021-06-29 7:02 ` Petr Vorel
2021-06-29 8:12 ` Jan Stancek
2021-06-29 10:32 ` Li Wang
0 siblings, 2 replies; 5+ messages in thread
From: Petr Vorel @ 2021-06-29 7:02 UTC (permalink / raw)
To: ltp
Hi,
> Lockdown requires signed modules, otherwise tests fails with EPERM.
> TCONF until we solve signing modules in LTP build.
BTW up now only 4 tests are using tst_lockdown_enabled() check, but maybe it's a
time to add flag .skip_on_lockdown, as docparse would benefit from it.
Kind regards,
Petr
^ permalink raw reply [flat|nested] 5+ messages in thread
* [LTP] [PATCH 1/1] delete_module0{1, 3}: Skip when kernel is locked down
2021-06-29 7:02 ` Petr Vorel
@ 2021-06-29 8:12 ` Jan Stancek
2021-06-29 10:32 ` Li Wang
1 sibling, 0 replies; 5+ messages in thread
From: Jan Stancek @ 2021-06-29 8:12 UTC (permalink / raw)
To: ltp
On Tue, Jun 29, 2021 at 9:02 AM Petr Vorel <pvorel@suse.cz> wrote:
> Hi,
>
> > Lockdown requires signed modules, otherwise tests fails with EPERM.
> > TCONF until we solve signing modules in LTP build.
>
Acked-by: Jan Stancek <jstancek@redhat.com>
> BTW up now only 4 tests are using tst_lockdown_enabled() check, but maybe
> it's a
> time to add flag .skip_on_lockdown, as docparse would benefit from it.
>
I guess we'll find more over time.
>
> Kind regards,
> Petr
>
> --
> Mailing list info: https://lists.linux.it/listinfo/ltp
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linux.it/pipermail/ltp/attachments/20210629/aa3e9b00/attachment-0001.htm>
^ permalink raw reply [flat|nested] 5+ messages in thread
* [LTP] [PATCH 1/1] delete_module0{1, 3}: Skip when kernel is locked down
2021-06-29 7:02 ` Petr Vorel
2021-06-29 8:12 ` Jan Stancek
@ 2021-06-29 10:32 ` Li Wang
2021-06-29 12:15 ` Petr Vorel
1 sibling, 1 reply; 5+ messages in thread
From: Li Wang @ 2021-06-29 10:32 UTC (permalink / raw)
To: ltp
On Tue, Jun 29, 2021 at 3:02 PM Petr Vorel <pvorel@suse.cz> wrote:
> Hi,
>
> > Lockdown requires signed modules, otherwise tests fails with EPERM.
> > TCONF until we solve signing modules in LTP build.
> BTW up now only 4 tests are using tst_lockdown_enabled() check, but maybe
> it's a
> time to add flag .skip_on_lockdown, as docparse would benefit from it.
>
Make sense!
Acked-by: Li Wang <liwang@redhat.com>
--
Regards,
Li Wang
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linux.it/pipermail/ltp/attachments/20210629/73dd714b/attachment.htm>
^ permalink raw reply [flat|nested] 5+ messages in thread
* [LTP] [PATCH 1/1] delete_module0{1, 3}: Skip when kernel is locked down
2021-06-29 10:32 ` Li Wang
@ 2021-06-29 12:15 ` Petr Vorel
0 siblings, 0 replies; 5+ messages in thread
From: Petr Vorel @ 2021-06-29 12:15 UTC (permalink / raw)
To: ltp
Hi Jan, Li,
thanks for your review, merged!
Kind regards,
Petr
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2021-06-29 12:15 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-29 6:58 [LTP] [PATCH 1/1] delete_module0{1, 3}: Skip when kernel is locked down Petr Vorel
2021-06-29 7:02 ` Petr Vorel
2021-06-29 8:12 ` Jan Stancek
2021-06-29 10:32 ` Li Wang
2021-06-29 12:15 ` Petr Vorel
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.