Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

PATCH: Allow more scripts without #!



This change updates the binary safety check so that zsh can run shell scripts with concatenated binary content within the first 128 bytes, provided a line exists beforehand with a lowercase character or shell expansion syntax. Note that this only impacts classic implicit shell scripts which don't have a shebang line.

POSIX rules were updated to loosen binary restrictions and require this behavior going forward. A similar change was made last year to the FreeBSD Almquist Shell. It's needed by projects such as the Cosmopolitan C Library, which creates polyglot executables that run on all operating systems.

I release this change into the public domain. See unlicense / creative commons cc0.

Attachment: execve.patch
Description: Binary data



Messages sorted by: Reverse Date, Date, Thread, Author