path: root/arch/i386
diff options
authorRich Felker <>2012-10-15 11:42:46 -0400
committerRich Felker <>2012-10-15 11:42:46 -0400
commitd5304147b983f309ed0c9050e3b8b6f2c9f87f43 (patch)
treee388817e710423d6b27ce1b8c6a354c34a4f09e4 /arch/i386
parent42c36f957d54926eec87b072a73439b9a1539347 (diff)
block uid/gid changes during posix_spawn
usage of vfork creates a situation where a process of lower privilege may momentarily have write access to the memory of a process of higher privilege. consider the case of a multi-threaded suid program which is calling posix_spawn in one thread while another thread drops the elevated privileges then runs untrusted (relative to the elevated privilege) code as the original invoking user. this untrusted code can then potentially modify the data the child process will use before calling exec, for example changing the pathname or arguments that will be passed to exec. note that if vfork is implemented as fork, the lock will not be held until the child execs, but since memory is not shared it does not matter.
Diffstat (limited to 'arch/i386')
0 files changed, 0 insertions, 0 deletions