A cybersecurity-focused educational project that demonstrates how keystroke data can be captured, transmitted, stored, and viewed using a client-server architecture.
This project consists of two independent components:
- Python Keylogger – Captures keystrokes and sends them to a remote server.
- Node.js Server – Receives, timestamps, stores, and displays captured data through a web interface.
Educational Purpose Only
This project was developed for cybersecurity learning, research, and demonstration purposes in a controlled environment. It is intended to help students and security enthusiasts understand how monitoring systems work and how such techniques may be detected, analyzed, and mitigated.
┌─────────────────┐
│ Python Keylogger│
│ │
│ • Capture Keys │
│ • Get Username │
│ • Buffer Data │
└────────┬────────┘
│ HTTP POST
▼
┌─────────────────┐
│ Node.js Server │
│ │
│ • Receive Data │
│ • Add Timestamp │
│ • Save Logs │
│ • Display Logs │
└────────┬────────┘
│
▼
┌─────────────────┐
│ Log File │
│ │
│ keyboard_ │
│ capture.txt │
└─────────────────┘
Responsible for:
- Capturing keyboard input
- Capturing the current username
- Buffering keystroke data
- Sending data to the server via HTTP
- Running in the background
Directory
Python-Keylogger/
Responsible for:
- Receiving client data
- Processing incoming requests
- Adding timestamps
- Storing logs in a text file
- Providing a browser-based log viewer
Directory
node-server/
- Python
- pynput
- requests
- threading
- json
- getpass
- Node.js
- Express.js
- File System (fs)
Keystroke-Logging-System/
│
├── Python-Keylogger/
│ ├── keylogger.py
│ ├── requirements.txt
│ └── README.md
│
├── node-server/
│ ├── server.js
│ ├── commands.txt
│ └── README.md
│
└── README.md
- User types on the keyboard.
- Python client captures keystrokes.
- Data is buffered and processed.
- Client sends the data to the Node.js server via HTTP POST.
- Server receives the data.
- Timestamp and username are added.
- Data is stored in
keyboard_capture.txt. - Logs can be viewed through the browser dashboard.
git clone https://github.com/zer0arc4/Keystroke-Logging-System.git
cd Keystroke-Logging-Systemcd node-server
npm install
node server.jsServer will start at:
http://localhost:8080
Open another terminal:
cd Python-Keylogger
pip install -r requirements.txt
python keylogger.py[03/28/2026, 10:15:23 AM]=[User:zer0arc4]
hello world
[03/28/2026, 10:17:02 AM]=[User:zer0arc4]
testing data transfer
- Real-time keystroke capture
- Username collection
- Data buffering
- HTTP-based transmission
- Background execution
- RESTful POST endpoint
- Live browser log viewer
- Automatic timestamping
- Persistent log storage
- Basic error handling
This project demonstrates:
- Keyboard event monitoring
- Client-server communication
- HTTP requests
- Data logging
- File handling
- Web server development
- Cybersecurity monitoring concepts
The public version intentionally excludes advanced offensive techniques such as:
- Persistence mechanisms
- Process injection
- Evasion techniques
- Anti-analysis features
- Credential extraction
For deployments outside a local lab environment, consider implementing:
- HTTPS
- Authentication
- Authorization
- Access controls
- Input validation
- Log sanitization
- Secure storage practices
Additional setup and usage instructions are available inside:
Python-Keylogger/README.mdnode-server/README.md
This project is intended solely for educational, research, and cybersecurity training purposes in environments where explicit authorization has been granted.
The author is not responsible for any misuse, unauthorized deployment, or activities that violate applicable laws, regulations, or organizational policies.
Alakati Rithesh Chandra (zer0arc4)
GitHub: https://github.com/zer0arc4
If you find this project useful, consider giving it a ⭐ on GitHub.