Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The SSH tube now keeps the environment variable's order. (#1464)
* The SSH tube now keeps the environment variables of processes it creates in order. The way of achieving that is through passing the env to the script as a list of tuples, since Python3's dictionaries are ordered by default, or you can use `OrderedDict`, the result would be that the spawned process on the remote machine will keep the environment variables in order. This is very important to exploits that are based on the stack's order and especially the environment variables. For instance, a common challenge is comparing argc == 0, and afterwards accessing the argv array, as an out-of-bounds array. The shellcode needs to be at a certain index consistently and cannot rely on the stack moving around. * Relocated the code.
- Loading branch information