calebstewart / pwncat

Fancy reverse and bind shell handler
https://pwncat.readthedocs.io
MIT License
2.63k stars 258 forks source link

Added Linux which fallback routine #198

Closed calebstewart closed 3 years ago

calebstewart commented 3 years ago

Description of Changes

Added a custom _do_custom_which method to the Linux platform. During initialization, if a local implementation of which is not found, pwncat will default to using this custom which implementation, which looks roughly like:

/bin/bash -c 'IFS='"':'"'; for path in $PATH; do if [ -f "$path/$binary_name" ]; then echo "$path/$binary_name"; fi; done; IFS='"' '"

Fixes #193.

Major Changes Implemented:

Pre-Merge Tasks