Hey Jilles, * Jilles Tjoelker <jilles_at_stack.nl> wrote: > This KASSERT may happen if you execute a setuid/setgid program with one > or more of fd 0, 1, 2 closed, and you cannot open /dev/null (e.g. not > present, bad permissions). The assertion checks td->td_retval[0] even if > kern_open() failed. After that, if td->td_retval[0] happened to be equal > to the expected value or INVARIANTS was disabled, the function checks if > kern_open() failed. If so, it returns an error which eventually causes > "whoops, no process anymore" process termination in do_execve() (appears > as SIGABRT). Too bad we don't have some kind of global nullfd that we could just dup everywhere. I really don't like the way how we depend on certain pathnames within the kernel. -- Ed Schouten <ed_at_80386.nl> WWW: http://80386.nl/
This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:49 UTC