Re: [PATCH] uprobes: fix kernel info leak via "[uprobes]" vma

From: Oleg Nesterov
Date: Sun Sep 29 2024 - 10:50:33 EST


On 09/29, Masami Hiramatsu wrote:
>
> On Thu, 26 Sep 2024 18:29:01 +0200
> Oleg Nesterov <oleg@xxxxxxxxxx> wrote:
>
> > xol_add_vma() maps the uninitialized page allocated by __create_xol_area()
> > into userspace. On some architectures (x86) this memory is readable even
> > without VM_READ, VM_EXEC results in the same pgprot_t as VM_EXEC|VM_READ.
>
> Good catch!
> I think we push this urgently and send it to stable tree too, right?

Agreed, can you route this patch?

> Fixes: d4b3b6384f98 ("uprobes/core: Allocate XOL slots for uprobes use")
> Cc: stable@xxxxxxxxxxxxxxx

Will add this or should I resend with these tags included ?

perhaps the changelog should mention that debugger can read this memory
regardless of pgprot_t...

> Acked-by: Masami Hiramatsu (Google) <mhiramat@xxxxxxxxxx>

Thanks!

Oleg.