So I was taking a look at the RUN extension and noticed that he used ducky script inside his function. I tried to recreate that but with my own set of ducky commands but it doesn't seem to execute?
....extension (eject.sh)
#!/bin/bash
#
# Eject storage v1 by vo1d
# opens powershell to eject flash device
# Requires Windows
# Usage: EJECT name of device
#
# Examples:
# EJECT BashBunny
function EJECT(){
local dvn = $1
shift
[[ -z "$dvn" ]] && exit 1 # parameter must be set
LED R B FAST
sleep 5
QUACK GUI
QUACK DELAY 100
QUACK STRING "powershell"
QUACK DELEAY 100
QUACK CTRL-SHIFT ENTER
QUACK DELAY 500
QUACK ALT y
QUACK DELAY 200
LED R SLOW
sleep 5
QUACK STRING "\$dvn = (gwmi win32_volume -f 'label=''$dvn''' | Select-Object -ExpandProperty DriveLetter)"
QUACK DELAY 100
QUACK ENTER
QUACK DELAY 100
QUACK STRING "\$Eject = New-Object -comObject Shell.Application"
QUACK DELAY 100
QUACK ENTER
QUACK DELAY 100
QUACK STRING "\$Eject.NameSpace(17).ParseName(\$dvn).InvokeVerb(\"Eject\")"
QUACK DELAY 100
QUACK ENTER QUACK DELAY 100
}
export -f EJECT
...payload (payload.txt)
ATTACKMODE HID
EJECT BashBunny