A simple keylogger developed as an assignment for Information Security Course (CSL 466).
A keylogger that records the keystrokes entered by a user and logs them in a file. Logs files are emailed to a specific address after a specific interval of time. Log files contain system information at the start followed by a list of keys along with the timestamps at which they were pressed and released.
- Clone this repo and name it accordingly:
git clone [email protected]:killtheverse/keylogger.git MY-PROJECT && cd MY-PROJECT
- Install dependencies:
pip install -r requirements.txt
- Setup a burner email account. Make sure that 2 factor authentication is disabled. If using a gmail account, make sure that "Less secure login is enabled".
- Create a .env file in the root directory and enter the email credentials as:
EMAIL=<YOUR EMAIL>
PASSWORD=<YOUR PASSWORD>
For example if your email is [email protected]
and password is password123
, then the .env file should look like:
[email protected]
PASSWORD=password123
- In keylogger.py, change the value of
REPORTING_INTERVAL
andSTOP
to the desired values.REPORTING_INTERVAL
denotes the interval time (in seconds) after which the emails will be sent with logs.STOP
if set toTrue
will stop the keylogger when the user presses the escape key. - Run
python keylogger.py
The reports have been generated using VirusTotal
- The python script is not detected by any anti virus software - report
- The executable is detected by 20/69 security vendors - report
- Add additional listeners to keylogger such as capturing screenshots or recording audio.
- Add additional methods to transfer files from host machines.
- Add a functionality so that keylogger automatically starts itself after the boot process.
This project has been inspired by https://github.com/aydinnyunus/Keylogger