arget13 / DDexec

A technique to run binaries filelessly and stealthily on Linux by "overwriting" the shell's process with another.
GNU General Public License v3.0
798 stars 83 forks source link

Change shebang as scripts are not POSIX-compliant #8

Closed Vincevrp closed 2 years ago

Vincevrp commented 2 years ago

By setting /bin/sh as the shebang, you declare that the script is POSIX-compliant. However, this is not the case.

As a consequence, this script would not run on distributions (such as Debian) who do not symlink /bin/sh to /bin/bash if executed using ./ddexec.sh.

Therefore, I think /bin/bash is more appropriate here.

References:

arget13 commented 2 years ago

Yeah, in the beginning the scripts had /bin/bash as shebang, but after I made them work in zsh and ash I thought I should change it. In the end it doesn't matter at all, this scripts are meant to be run like interpreter script.sh... so I am not pulling.

You may find other ways, perhaps more technical, to get involved. Thank you for your interest.