]> Zhao Yanbai Git Server - minix.git/commit
VFS: check X bit, not R bit, opening executables 68/3068/1
authorDavid van Moolenbroek <david@minix3.org>
Mon, 31 Aug 2015 12:12:28 +0000 (12:12 +0000)
committerDavid van Moolenbroek <david@minix3.org>
Mon, 31 Aug 2015 12:55:55 +0000 (12:55 +0000)
commit56ac45c10b294dc800c4cce9e53df7b2ae2495d2
treefc177535b22b25ee1cad197ab42eb8f5c65d7803
parent9f15e7b3660a0698d6bb068e277796ac37efa93c
VFS: check X bit, not R bit, opening executables

For dynamically linked executables, the interpreter is passed a
file descriptor of the binary being executed.  To this end, VFS
opens the target executable, but opening the file fails if it is
not readable, even when it is executable.  With this patch, when
opening the executable, it verifies the X bit rather than the R
bit on the file, thus allowing the execution of dynamically
linked binaries that are executable but not readable.

Add test86 to verify correctness.

Change-Id: If3514add6a33b33d52c05a0a627d757bff118d77
distrib/sets/lists/minix/mi
minix/servers/vfs/exec.c
minix/servers/vfs/misc.c
minix/servers/vfs/open.c
minix/servers/vfs/proto.h
minix/tests/Makefile
minix/tests/run
minix/tests/test86.c [new file with mode: 0644]