duckhunter icon indicating copy to clipboard operation
duckhunter copied to clipboard

STRING command not converting at all

Open MerdaInformatica opened this issue 4 years ago • 0 comments

Good night. See that no one post here from a lot of time, but this is my last chance LOL

I have Nethunter flashed to Android stock 6.0.1 on a Nexus 5. Works fine. Actually, everything seems fine but Duckhunter HID is just partially working. All common commands are sent correclty to Victim PC but STRING command is completely ignored by the converter.

i write down here a very simple example of a script non converting STRING command:

Input:: Ducky_tester.txt

DELAY 1000
GUI r
DELAY 1000
STRING notepad
DELAY 500
ENTER
DELAY 500
STRING its show time
DELAY 1000

Output in the preview (and what is then executed): Ducky_out

#!/system/bin/sh

## The script is converted by "us" keyboard layout ##
echo "[!] Executing duckyscript.."
echo "[!] Checking if HID driver has been installed on target machine.."
COUNT=0
until echo volume-up | /system/xbin/hid-keyboard /dev/hidg0 keyboard > /dev/null 2>&1; do
    sleep 1
    COUNT=$((COUNT+1))
    if [ $COUNT -eq 60 ]; then  #60 seconds
        echo "[-] HID driver still cannot be installed on target machine after $COUNT second....\nScript aborted."
        exit 1
    fi
done
echo "[+] HID driver is found installed on target machine already! Executing attack..."

/system/xbin/busybox_nh usleep 1000000
echo left-meta r | /system/xbin/hid-keyboard /dev/hidg0 keyboard
/system/xbin/busybox_nh usleep 1000000
/system/xbin/busybox_nh usleep 500000
echo enter | /system/xbin/hid-keyboard /dev/hidg0 keyboard
/system/xbin/busybox_nh usleep 500000
/system/xbin/busybox_nh usleep 1000000
echo "[+] Attack complete."

The Attack run every command except the STRING.

  1. Suggestions?
  2. I use an Italian keyboard, could be that the problem? I think not bc to me seems a conversion problem. But who knows.

MerdaInformatica avatar Dec 28 '20 21:12 MerdaInformatica