3 ms·
Why can't we just write `#!sh` I never understood. It's because #! is handled by the kernel, but the process environment is not parsed by the kernel.
by cperciva 4y ago
Why can't we just write `#!sh` I never understood.
It's because #! is handled by the kernel, but the process environment is not parsed by the kernel.
- vbezhenar 4y agoParsing PATH should not be that hard.
- bregma 4y agoSure add arbitrary user input string parsing to the privileged kernel in a place where programs are launched. The CVE database is pretty sparse as it is and could use a good churning. So, assuming the string is parsed safely and securely, does the kernel have enough semantic knowledge of paths to know which service to pass it to? Are the services guaranteed to be loaded and running at all times? Or is there an underlying architectural assumption that the kernel is a Linux-style monolith and POSIX no longer applies to micro- and nano-kernel systems?
- cperciva 4y agoIt isn't... now. On a PDP-11 with 40 kW of RAM, on the other hand...