From b68a2d51e77f27a582282f16ff127bbcf3bb7820 Mon Sep 17 00:00:00 2001 From: Ram Damera Date: Thu, 24 Oct 2019 21:48:44 +0530 Subject: [PATCH 1/2] change nc remote shell command to work on wide distros --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index fd06e76..62b5a10 100644 --- a/README.md +++ b/README.md @@ -3235,7 +3235,8 @@ client> tar czvfp - /path/to/dir | nc 10.240.30.3 5000 ###### Launch remote shell ```bash -server> nc -l 5000 -e /bin/bash +server> rm -f /tmp/f; mkfifo /tmp/f +server> cat /tmp/f | /bin/bash -i 2>&1 | nc -l 127.0.0.1 5000 > /tmp/f client> nc 10.240.30.3 5000 ``` From c8792783ec6fdd2137f8b3961db1bd9d21f3998a Mon Sep 17 00:00:00 2001 From: phk918 Date: Thu, 24 Oct 2019 20:51:59 +0200 Subject: [PATCH 2/2] minor update --- README.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/README.md b/README.md index 62b5a10..ac8888b 100644 --- a/README.md +++ b/README.md @@ -3235,6 +3235,11 @@ client> tar czvfp - /path/to/dir | nc 10.240.30.3 5000 ###### Launch remote shell ```bash +# 1) +server> nc -l 5000 -e /bin/bash +client> nc 10.240.30.3 5000 + +# 2) server> rm -f /tmp/f; mkfifo /tmp/f server> cat /tmp/f | /bin/bash -i 2>&1 | nc -l 127.0.0.1 5000 > /tmp/f client> nc 10.240.30.3 5000