Not always, no. Most applications using pam are marked setuid, or have setuid helpers -- as many standard plugins do require root -- but one can use the library without root privileges or an escalation method if no plugins being invoked need privileges. Some examples: Standard authentication with /etc/shadow does...
Check if the filesystem that $ORACLE_HOME is in, is mounted with the nosuid option. If it is, that will prevent any executable running as root, even if SUID bit is set. Hope that helps....
java,jetty,unsatisfiedlinkerror,jetty-9,setuid
Exploring the libsetuid file (nm -D /path/to/the/so), I realized that the so I was using was outdated and was not compatible with Jetty 9, the functions were named as mortbay: [email protected]:~/# nm -D libsetuid.so --size-sort | less 0000000000000010 T Java_org_mortbay_setuid_SetUID_setgid 0000000000000010 T Java_org_mortbay_setuid_SetUID_setuid 0000000000000015 T Java_org_mortbay_setuid_SetUID_setumask 0000000000000018 T throwNewJavaSecurityException 0000000000000058...
No problem with your code, just check correct setuid / 'sgid' sequence: sudo chmod 6775 setuid sudo chown root:root setuid You must set at least SUID, SGID and execution permissions (6555 mask). Also it's common for this case to set user/group write (6775 mask). Of course for security you can...
osx,bash,permissions,sudo,setuid
Use cp -p option to preserve file attributes. Note this will preserve user, group permissions and the modification and access times of the files....