Files
linux/fs/proc
Willy Tarreau 7f7ccc2ccc proc: do not access cmdline nor environ from file-backed areas
proc_pid_cmdline_read() and environ_read() directly access the target
process' VM to retrieve the command line and environment. If this
process remaps these areas onto a file via mmap(), the requesting
process may experience various issues such as extra delays if the
underlying device is slow to respond.

Let's simply refuse to access file-backed areas in these functions.
For this we add a new FOLL_ANON gup flag that is passed to all calls
to access_remote_vm(). The code already takes care of such failures
(including unmapped areas). Accesses via /proc/pid/mem were not
changed though.

This was assigned CVE-2018-1120.

Note for stable backports: the patch may apply to kernels prior to 4.11
but silently miss one location; it must be checked that no call to
access_remote_vm() keeps zero as the last argument.

Reported-by: Qualys Security Advisory <[email protected]>
Cc: Linus Torvalds <[email protected]>
Cc: Andy Lutomirski <[email protected]>
Cc: Oleg Nesterov <[email protected]>
Cc: [email protected]
Signed-off-by: Willy Tarreau <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
2018-05-17 09:27:47 -07:00
..
2018-04-11 10:28:34 -07:00
2018-04-13 17:10:27 -07:00
2018-04-11 10:28:34 -07:00
2018-04-20 17:18:36 -07:00
2017-11-17 16:10:00 -08:00
2018-04-11 10:28:34 -07:00
2018-04-11 10:28:34 -07:00
2018-02-06 18:32:43 -08:00
2018-02-06 18:32:43 -08:00
2017-11-17 16:10:00 -08:00