James G. Sack (jim) wrote:

2) but if a script is (say) o+x and (eg, for security) you wish the
script NOT to execute anything other than the known program at the known
absolute path, then you probably should hard code the path appropriate
for that host.

No.  For security, you should encode *no* path.

Paths can be faked; shared libraries can be corrupted; etc.

I can use LD_LIBRARY_PATH to replace the standard system path utilities and trick you into believing that the path is correct.

The concepts of "security", "script" and "user" are fundamentally incompatible.

This is why the admonition "No setuid scripts" exists.

-a


--
[email protected]
http://www.kernel-panic.org/cgi-bin/mailman/listinfo/kplug-list

Reply via email to