Eliminating LD_PRELOAD ERRORs with setuid programs
Peter Åstrand
astrand@cendio.se
Mon Apr 24 15:37:00 GMT 2006
We are using the LD_PRELOAD mechanism like this:
LD_PRELOAD=libfoo.so
LD_LIBRARY_PATH=/opt/ourproduct/lib64:/opt/ourproduct/lib
This works well for both 32 and 64 bit binaries, with one exception:
setuid programs, which gives:
ERROR: ld.so: object 'libfoo.so' from LD_PRELOAD cannot be preloaded: ignored.
How can we eliminate this error message? I've found out that it's actually
possible to use LD_PRELOAD with setuid programs if the library itself is
setuid and found in a standard directory.
However, we would prefer to have LD_PRELOAD (silently) ignored for setuid
programs. How can we achieve this?
Regards,
--
Peter Ã
strand ThinLinc Chief Developer
Cendio http://www.cendio.se
Teknikringen 3
583 30 Linköping Phone: +46-13-21 46 00
More information about the Libc-alpha
mailing list