With a netcat listener like:
nc -l <port> < ~/.bashrc
I can grab my .bashrc on a new machine (doesn't have nc
or LDAP) with:
cat < /dev/tcp/<ip>/<port> > ~/.bashrc
My question is: Is there a way to mimic the capabilities of nc -l <port>
in my first line with /dev/tcp instead of nc
?
The machines I'm working on are extremely hardened lab/sandbox environment RHEL (no ssh, no nc, no LDAP, no yum, I can't install new software, and they are not connected to the internet)