Re: [LTP] [PATCH v2] security/dirtyc0w_shmem: Add new test for CVE-2022-2590

Cyril Hrubis
2022-11-25T14:21:42Z

Hi!
> > + pid = SAFE_FORK();
> > + if (!pid) {
> > + SAFE_SETGID(nobody_gid);
> > + SAFE_SETUID(nobody_uid);
> > + SAFE_EXECLP("dirtyc0w_shmem_child", "dirtyc0w_shmem_child", NULL);
>
> Manpage says that the last argument of execlp() must be (char*)NULL,
> including the explicit typecast.

I wonder if this is actually valid. Do you know in which way is
different ((char*)0) from ((void*)0) ?

--
Cyril Hrubis
chrubis@suse.cz