All of lore.kernel.org
 help / color / mirror / Atom feed
From: linuxtestproject.agent@gmail.com
To: Andrea Cervesato <andrea.cervesato@suse.de>
Cc: ltp@lists.linux.it
Subject: Re: [LTP] syscalls/cma: Require root for process_vm tests
Date: Wed, 14 Oct 2026 11:24:06 +0000	[thread overview]
Message-ID: <20261014112407.9439-1-linuxtestproject.agent@gmail.com> (raw)
In-Reply-To: <20261014-fix_process_vm_writev_permissions-v1-1-6affee2da859@suse.com>

Hi Andrea,

On 14 October 2026, Andrea Cervesato wrote:
> syscalls/cma: Require root for process_vm tests

> diff --git a/testcases/kernel/syscalls/cma/process_vm_readv02.c b/testcases/kernel/syscalls/cma/process_vm_readv02.c
> @@ -116,6 +120,7 @@ static struct tst_test test = {
>  	.test_all = run,
>  	.setup = setup,
>  	.cleanup = cleanup,
> +	.needs_root = 1,
>  	.forks_child = 1,
>  	.needs_checkpoints = 1,

Across all three tests, this skips valid non-root runs when Yama is
disabled or ptrace_scope=0, yet UID 0 without CAP_SYS_PTRACE still passes
the framework's geteuid() check and gets EPERM under modes 1/2.
For mode 1, have the target call prctl(PR_SET_PTRACER, getppid(), ...)
before signalling readiness to authorize the parent and its descendants,
including the sibling.
Preserve unprivileged execution where allowed and use tst_cap_action()
with TST_CAP_REQ when CAP_SYS_PTRACE is actually needed, so missing
capabilities produce TCONF.

Verdict - Needs revision

---
Note:

The agent can sometimes produce false positives although often its
findings are genuine. If you find issues with the review, please
comment this email or ignore the suggestions.

Regards,
LTP AI Reviewer

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

      reply	other threads:[~2026-10-14 11:24 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-14  8:21 [LTP] [PATCH] syscalls/cma: Require root for process_vm tests Andrea Cervesato
2026-10-14 11:24 ` linuxtestproject.agent [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=20261014112407.9439-1-linuxtestproject.agent@gmail.com \
    --to=linuxtestproject.agent@gmail.com \
    --cc=andrea.cervesato@suse.de \
    --cc=ltp@lists.linux.it \
    /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 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.