USB-Rubber-Ducky
USB-Rubber-Ducky copied to clipboard
c_duck_osx.hex doesn't work anymore
I have done the following:
Plugged in the rubber ducky and holding down the reset button when I plug it in to enter dfu mode.
$ dfu-programmer at32uc3b1256 erase
$ dfu-programmer at32uc3b1256 flash --suppress-bootloader-mem ~/Desktop/hak/rubber_ducky/USB-Rubber-Ducky/Firmware/Images/osx.hex
$ dfu-programmer at32uc3b1256 reset
After flashing the firmware of the rubberducky with osx.hex
I loaded the following test script and encoded it to inject.bin using
java -jar ~/Desktop/hak/rubber_ducky/duckencoder.jar -i ~/Desktop/hak/rubber_ducky/test.txt -o /Volumes/_/inject.bin
I plug the microsd card into the rubber ducky, move to another mac and it executes perfectly.
Now I repeat the process, but instead of osx.hex I load c_duck_osx.hex
When I plug it into a test machine, the microsd card mounts as expected, however, the inject.bin does not run. The rubber ducky blinks red. I have checked the help files and can verify that it can read the microsd card based on the fact that it is mounting the card.
Is there a fix for this or did I do something wrong? Ideally I'd like to get this running on a mac so I can run the twin duck firmware
The java duck encoder version is: Hak5 Duck Encoder 2.6.4 from https://github.com/hak5darren/USB-Rubber-Ducky/blob/master/Encoder/encoder.jar
The test inject.bin code is the following. The DELAY at the beginning was at 1000 and I increased it to 10000 in order to see if it was an issue of trying to run something before the drive was mounted. It has no effect on behavior. Still blinks red. Sometimes it will alternate between green and red, but that is only when the drive is in the process of mounting. After that, it just blinks off and on red.
DEFAULTDELAY 250
REM Wait for the system to get all set up
DELAY 10000
REM Open the "Spotlight Search" and pull up the terminal/cli
GUI SPACE
STRING Terminal.app
ENTER
REM Send a command to the machine through the terminal/cli
STRING say 'you have been hacked'
ENTER
DELAY 2000
REM Close the terminal window so there's no trace left behind
GUI q
Please help.
A very similar thing happened with me, although for me the Ducky actually works. I flashed the same Twin Duck firmware the same way that you did (via dfu programmer), and my script was to "steal" a file from the computer.
When I plugged in the Ducky, it did alternate between blinking green and red, but it still executed the inject.bin file. My advice would be to re-flash the firmware and perhaps you can try to use a different encoder. This encoder always worked for me (just make sure to set the proper keyboard type).
As for your code, it works perfectly fine on my Ducky (you just have to wait a while because of that initial delay).
I hope this helps.