Open derekbruening opened 7 years ago
The bulk of this is in 1b763ba775b8f43fff347ff90eaa628bdc3af942
Please update the docs for this as well, which today say: "When running scripts it is best to explicitly invoke the interpreter rather than invoking the script directly"
For late injection I would expect things to mostly work. However, this is not something that we have spent any time on, and we have no tests of it, so there may well be something that is not quite right such as when looking up child config vars or when trying to handle cross-arch (i.e., 32-bit app execs 64-bit child) due to failing to get the proper final ELF binary.
For early injection, however, I would expect DR to actually need to parse the magic comment for correct execution of the proper binary, b/c it passes the app path to itself on the other side. This will be a pain b/c it can recurse up to 4 times through other scripts.