Instituto Nacional de ciberseguridad. Sección Incibe
Instituto Nacional de Ciberseguridad. Sección INCIBE-CERT

CVE-2026-68187

Gravedad:
Pendiente de análisis
Tipo:
No Disponible / Otro tipo
Fecha de publicación:
10/08/2026
Última modificación:
19/08/2026

Descripción

*** Pendiente de traducción *** In the Linux kernel, the following vulnerability has been resolved:<br /> <br /> exec: fix unsigned loop counter wrap in transfer_args_to_stack()<br /> <br /> The stop value is derived from bprm-&gt;p &gt;&gt; PAGE_SHIFT. The index variable<br /> is an unsigned long. If bprm-&gt;p drops below PAGE_SIZE and stop becomes<br /> zero the loop condition index &gt;= stop is always true.<br /> <br /> After the index == 0 iteration the decrement wraps to ULONG_MAX and<br /> bprm-&gt;page[ULONG_MAX] reads sizeof(void *) bytes in front of the array.<br /> The pointer has wrapped to -1. That garbage pointer is then passed to<br /> kmap_local_page() and PAGE_SIZE bytes are copied from wherever that<br /> lands into the stack of the process being created. And the loop doesn&amp;#39;t<br /> terminate either...<br /> <br /> Getting there only requires bprm-&gt;p p is pushed down is valid_arg_len(), i.e.<br /> that each individual string still fits in what is left.<br /> <br /> bprm-&gt;p starts at PAGE_SIZE * MAX_ARG_PAGES - sizeof(void *) so a<br /> single argument or environment string of a little over 31 pages leaves<br /> it in the first page:<br /> <br /> Oops - load access fault [#1]<br /> CPU: 0 UID: 0 PID: 1 Comm: victim Not tainted 7.2.0-rc4 #1<br /> epc : __memcpy+0xd4/0xf8<br /> ra : transfer_args_to_stack+0xaa/0xae<br /> s4 : ffffffffffffffff s2 : 0000000000000000<br /> a1 : ffffffdc98000000 a2 : 0000000000001000<br /> status: 0000000a00001880 badaddr: ffffffdc98000000 cause: 0000000000000005<br /> [] __memcpy+0xd4/0xf8<br /> [] load_flat_binary+0x43a/0x65e<br /> [] bprm_execve+0x1d4/0x316<br /> [] do_execveat_common+0x12e/0x138<br /> [] __riscv_sys_execve+0x38/0x4e<br /> Kernel panic - not syncing: Fatal exception in interrupt<br /> <br /> This is an arcane bug but we should still fix it.<br /> <br /> Count down from MAX_ARG_PAGES so the loop ends when index reaches stop,<br /> stop == 0 included. The iterations performed are unchanged for every<br /> other value of stop.<br /> <br /> Only CONFIG_MMU=n builds are affected, transfer_args_to_stack() is used<br /> by binfmt_flat and binfmt_elf_fdpic on nommu only.<br /> <br /> The loop predates git history. commit 7e7ec6a93434<br /> ("elf_fdpic_transfer_args_to_stack(): make it generic") only moved it<br /> from binfmt_elf_fdpic.c into fs/exec.c and narrowed the copy to the used<br /> part of the first page. The condition and the decrement are unchanged<br /> from 2.6.12-rc2.

Impacto