Be aware of setting a setuid bit on a root - owned file with native code that uses jni invocation api 对于具有使用jni invocation api的本地代码的所有者为root的文件,要记得设置setuid位。
We ve seen this sort of situation lead to entire directories of programs needlessly set setuid root . once again , very bad 我们宁可看到人们选择高质量的口令并将它们写下来,因为我们认为这种方法不太可能泄露它们。
If non - root starts such a root - owned setuid bit - set executable , ld library path is cleared for security and necessary libraries are therefore not found . it might be necessary to set the ld library path global variable to point to the location of the newly created shared library and jvm libraries in . jre bin classic and . jre bin directories 如果非root用户启动了这种所有者为root而且设置了setuid的可执行文件,出于安全, ld _ library _ path会被清除,从而将找不到所需要的程序库。
setuid and setgid (short for "set user ID upon execution" and "set group ID upon execution", respectively)William von Hagen Ubuntu Linux Bible p.3-59 are Unix access rights flags that allow users to run an executable with the permissions of the executable's owner or group respectively and to change behaviour in directories.