VoidNoi / BadCard

BadUSB for the Cardputer with ducky script support and extra functionality
GNU General Public License v3.0
67 stars 8 forks source link

Issue with STRING #1

Closed Banana-Phoney closed 6 months ago

Banana-Phoney commented 6 months ago

Hello

First off all thank you! This is the thing I wanted the most in the Cardputer! I do have some issues though. In the example below the last string is not written. I have tested a few variants with different text and writing into different programs.

I don't know much about programming the Cardputer, but tell me if i can help out with something.

DELAY 3000 GUI r DELAY 1000 STRING powershell DELAY 500 ENTER DELAY 3000 STRING hello

BR!

VoidNoi commented 6 months ago

I've tried the payload in both linux and windows and it's working as it should for me. Just to be clear, the last string would be "hello" right?

Banana-Phoney commented 6 months ago

Thank you for answering!

So I tested some more. The script ended at "STRING hello" (without a new line below) for me, but it worked a bit better if i added a new line below. It didn't get to more than he of hello, but It worked best if i added a delay after the string like in the example below. I have tested on multiple computers. All Windows machines and none especially fast or good.

The example: DELAY 3000 GUI r DELAY 1000 STRING powershell DELAY 500 ENTER DELAY 3000 STRING hello DELAY 500

BR

VoidNoi commented 6 months ago

Could you try executing this with a notepad open and show me a picture of the result? Also please put your payload in a code block to make it look better and delimit what is part of it

DELAY 1000
STRING Hello this is a test
ENTER
STRING Test 1 
STRING Test 2
Banana-Phoney commented 6 months ago

I tested that script, but now I was able to use a USB rubber ducky aswell and i ran into the same with that one. when i click a random key parts of the last string gets completed. I can press "w" 6 times to get it to fill out Test 2. pressing print

image

Do you not run into this? I have tried it on 5 different machines and with both a Cardputer and a USM rubber ducky

VoidNoi commented 6 months ago

I have tested this on Arch linux, nixOS, and Windows 10 on my main machine, Archcraft on another laptop and Fossapup on another one and I can't reproduce your problem. Only thing that comes to mind is that it might be a problem with windows 11. Do all of the machines you have tested this on use Windows 11?

Banana-Phoney commented 6 months ago

I thought i had tested on Windows 10, but i must not have. Tested a few machines now but also tested on Windows 10 and Pop os and it worked perfectly on them while i run into the issue on Windows 11. In other words, the issue has nothing to do with your firmware here! Thank you for helping me out! Also could be an idea to tell people add a delay at the end if they have a issue with windows 11. DELAY 500 worked for me there!

VoidNoi commented 6 months ago

That's great to hear, I hope microsoft fixes all the problems they have with drivers on Windows 11 soon. I'll be adding that suggestion to the readme, thanks for your feedback! Closing this issue now.

Velocity-50 commented 6 months ago

Hi, so whenever I am typing in a string and put a delay after it and than enter, it wont do it. I am using a cardputer. Here is my code: DELAY 500 WINDOWS r DELAY 500 STRING powershell DELAY 500 ENTER DELAY 500 STRING xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx DELAY 1000 ENTER

Velocity-50 commented 6 months ago

Hi, I have an idea for adding a command: STRING+ENTER. I have seen this command in other DuckyScript payloads and its very handy!

VoidNoi commented 6 months ago

@Velocity-50 Please create a new issue and put your code in a code block as I said in another comment

Also please put your payload in a code block to make it look better and delimit what is part of it