|author||Rich Felker <email@example.com>||2012-06-06 11:21:28 -0400|
|committer||Rich Felker <firstname.lastname@example.org>||2012-06-06 11:21:28 -0400|
treat failure of mprotect in map_library as a fatal load failure
the error will propagate up and be printed to the user at program start time; at runtime, dlopen will just fail and leave a message for dlerror. previously, if mprotect failed, subsequent attempts to perform relocations would crash the program. this was resulting in an increasing number of false bug reports on grsec systems where rwx permission is not possible in cases where users were wrongly attempting to use non-PIC code in shared libraries. supporting that usage is in theory possible, but the x86_64 toolchain does not even support textrels, and the cost of keeping around the necessary information to handle textrels without rwx permissions is disproportionate to the benefit (which is essentially just supporting broken library setups on grsec machines). also, i unified the error-out code in map_library now that there are 3 places from which munmap might have to be called.
Diffstat (limited to 'lib')
0 files changed, 0 insertions, 0 deletions