| ▲ | feelamee 7 hours ago | |
can someone explain security consideration of placing scripts into $HOME? Some time ago I moved all my scripts to /usr/local/bin, because I feel that this is better from security perspective. | ||
| ▲ | Galanwe 7 hours ago | parent | next [-] | |
There are no security implications, on the contrary. It is objectively cleaner to keep your user scripts in your home, that way they are only in _your_ PATH, whereas putting them in /usr/[local/]bin implicitly adds them to every [service] user on the machine, which I can see creating obscure undesired effets. Not even mentioning the potential issues with packages that could override your scripts at install, unexpected shadowing of service binaries, setuid security implications, etc. | ||
| ▲ | layer8 6 hours ago | parent | prev [-] | |
Someone with access to your home dir can also set your $PATH and aliases to anything they want, so I don’t see any extra security considerations here. | ||