Sign in to follow this  
Followers 0
tom13

Lowest level keyboard input (using a dll)

28 posts in this topic

Hi there,

I have heard that programs are able to notice the difference between keyboard input and AutoIT's send function. So, I was wondering, is there a lower level keyboard input dll so that applications won't be able to notice a difference and thus detect the "fake" keyboard input?

Thanks in advance.

- Tom

PS. I already have such function for the mouse, MouseMovePlus(). See:

Func _MouseMovePlus($X, $Y,$absolute = 0)
    Local $MOUSEEVENTF_MOVE = 1
    Local $MOUSEEVENTF_ABSOLUTE = 32768
    DllCall("user32.dll", "none", "mouse_event", _
            "long",  $MOUSEEVENTF_MOVE + ($absolute*$MOUSEEVENTF_ABSOLUTE), _
            "long",  $X, _
            "long",  $Y, _
            "long",  0, _
            "long",  0)
EndFunc

Share this post


Link to post
Share on other sites



please correct me someone if i am wrong but i do belive the user32.dll dll has the ability to send keystrokes as well... i would reccomend you search google for something along the lines of "sending keystrokes with win32.dll"

sorry this probably isnt of much help.

Share this post


Link to post
Share on other sites

Unless the internal structure of AutoIt has changed for the Send and MouseClick functions, they use the user32 functions. Those functions will add an extra parameter that indicates a simulated stroke. I've actually written a global hook that can differentiate between real user and software simulated input. You'd have to go lower than user32 I think.

Share this post


Link to post
Share on other sites

Unless the internal structure of AutoIt has changed for the Send and MouseClick functions, they use the user32 functions. Those functions will add an extra parameter that indicates a simulated stroke. I've actually written a global hook that can differentiate between real user and software simulated input. You'd have to go lower than user32 I think.

Ah thanks.

So I need a lower level dllcall for mousemovement aswell.

Anyone can help with any of these?

Share this post


Link to post
Share on other sites

I believe you'd need an understanding of drivers. Don't quote me on that though.

Share this post


Link to post
Share on other sites

#6 ·  Posted (edited)

So this is not possible by using DLLCalls with AutoIt?

Edit: If so, maybe there is some third party command line tool that could do such task when run? (press keys, move mouse)

Edited by tom13

Share this post


Link to post
Share on other sites

As Richard said, the only way is to make your own driver. DllCalls will get recognized as simulated keystrokes. 3rd party program might also get recognized as simulated keystrokes if they doesn't use a custom driver.

Share this post


Link to post
Share on other sites

A custom driver? why can't everyone use the same driver? Isn't there such driver on the web, or a third party program that uses it?

Share this post


Link to post
Share on other sites

#9 ·  Posted (edited)

You can find some drivers if you google it(most of the time where you can find hacks for games), however most likely they will not work for you so you will end up with writing your own driver or just screw the idea.

Try google for "fake keyboard driver".

Edited by Pain

Share this post


Link to post
Share on other sites

You can find some drivers if you google it(most of the time where you can find hacks for games), however most likely they will not work for you so you will end up with writing your own driver or just screw the idea.

Try google for "fake keyboard driver".

Thanks, the program called SCANCODE at http://home.att.net/~short.stop/freesoft/keyb.htm looks interesting.

Is there any way to check if programs are able to detect the difference between this program and a real keyboard?

Share this post


Link to post
Share on other sites

Unless the internal structure of AutoIt has changed for the Send and MouseClick functions, they use the user32 functions. Those functions will add an extra parameter that indicates a simulated stroke. I've actually written a global hook that can differentiate between real user and software simulated input. You'd have to go lower than user32 I think.

I assume it's possible.

Share this post


Link to post
Share on other sites

I assume it's possible.

Obviousely, or this whole thread would be pointless.

As I am sure you have understand I meant to ask whether there's any method I am able to use to find out what I need to know.

Share this post


Link to post
Share on other sites

Write to me if you get how to do it (through PM/warioren@hotmail.com)

Thanks

Regards Humper


[center][/center]

Share this post


Link to post
Share on other sites

It's impossible to check if a program differentiates between virtual and physical keypresses without a knowledge of debugging/digging or the source code.

Share this post


Link to post
Share on other sites

Thanks people.

Unfortunately I lack the knowledge to create such program myself.

I understand that there is no third party program which could scan for a difference between fake input and real input, already?

- Tom

Share this post


Link to post
Share on other sites

So basically you're wanting to be able to bypass, say a firewall or an anti-virus from detecting that you're sending keystrokes to a hidden irc-client/similar? :P

Share this post


Link to post
Share on other sites

Or most likely to be able to cheat on a game with anticheat protection.

Share this post


Link to post
Share on other sites

I'm pretty sure it's the latter. I've not seen a firewall that does anything to keystrokes.

Share this post


Link to post
Share on other sites

It is the latter, yes.

But that does not really influence the problem or situation.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0