I know how to make a keylogger using SetWindowHookEx. But I want to know if there is some way to open an IO port and input data that will tell me what key is pressed?
Posted on 2002-06-05 19:38:11 by Andareed
Not sure myself, but i have to ask, why?
Posted on 2002-06-05 21:45:10 by NaN
I've seen a "program" wich does this... it's a hardware-keylogger. You plug it between your keyboard cable and the PS/2 adapter in your machine. It logs about 10kb of text and is configurable with a masterpassword. Just open notepad or anything else, type the Password and it will print it's menu into the Notepad window from where you can select all options like displaying cache, deleting, setting password etc. Very nice thing for $50.
Think that is, what you wanna do, eh? Best would be if you stay with standard Windows API. But don't use that stupid Hook stuff :rolleyes:

regards,
bAZiK
Posted on 2002-06-06 00:52:19 by bazik
i'm not intending to jump in every semi 'malicious' thread, i'm
just curious of the last two sentences. what is meant with "use
apis but don't use hook apis" and why are hooks stupid? huh?
Posted on 2002-06-06 04:14:40 by mob
Well, I ment not to use the SetWindowHookEx stuff for that. I prefer hooking API's via memory patching :)
Posted on 2002-06-06 04:29:50 by bazik
ohw i first thought you're bored... yeah, andareed just should
just do a quik "memory patch" and all his problems should be
completly solved, very good idea.
Posted on 2002-06-06 04:46:04 by mob
:rolleyes:
Think he should better buy that hardware thing and reverse engineer it... :eek:
Posted on 2002-06-06 04:50:32 by bazik
So how can I do a "memory patch". In my first question, is there some port I can read from which will tell me what key is pressed?
Posted on 2002-06-06 08:38:28 by Andareed
In dos days you could hook int 9h, and then get the key scan codes etc

Cant in windows becuase it isolates you from the hardware, and with good reason too :-)

i did see some vxd or somthing out in the www that would (could) pass keys back to your app, but dont remember where
Posted on 2002-06-06 08:47:50 by Terab
andareed i doens't meant that serious... damn my english
must be REAL bad if you can't differ between severe and
sarcasm in this posting :) as far i know the record hook in
windows DOES retrieve the hardware input BEFORE it goes
in all these quenes and stuff, so it's exactly what you want.
record hooks don't even have to be located in a dll. but if
you really want to do this with IO ports, there was a IO lib
floating around a while ago here but i don't know the name
nor the handling. i can help you with hooks but i don't have
any clue on how to retrieve keyboard input from ports in a
stable and win32(!) compatible way...
Posted on 2002-06-06 08:59:43 by mob
Posted on 2002-06-06 09:14:52 by bazik
exactly :)
Posted on 2002-06-06 09:17:51 by mob
Thanks for the replies! You have been most helpful. BTW, bAZiK, i like your signature!
Posted on 2002-06-06 20:41:48 by Andareed
Thanks! :)
Posted on 2002-06-07 00:54:33 by bazik
the port is 0x60h and maybe you will also need port 0x64 for control...

but it will be hard to deal directly with such ports without a VxD on W9x or a KMD on NT.
Posted on 2002-06-07 03:10:22 by BogdanOntanu