Before you begin, ensure the following library is installed:
gcc -o nob nob.c
./nobIf target device is incorrect. Use the --dev <PATH> option to specify a device event. List available devices run ls -l /dev/input/by-id/
sudo out/keylogger --dev /dev/input/event7 --printkThere is a list of options available:
sudo out/keylogger [OPTIONS]
Options:
--dev [path] Specify the device event to use (default: /dev/input/event?)
--printk Show keystrokes in terminal
--port [port] Specify websocket port (default: 33300)
-h,--help Display help message and exitWant to try using Nix?
nix run github:ryhkml/keylogger -- --dev /dev/input/event? --printkThe keylogger server also supports secure WebSocket connections. Set an environment variable with the path to your certificate and private key files.
# Required
export KEYLOGGER_SSL_CERT_PATH="PATH_TO_CERT.pem"
export KEYLOGGER_SSL_KEY_PATH="PATH_TO_KEY.pem"
# Optional
export KEYLOGGER_SSL_CA_PATH=Just create an index.html file as a client to receive keystrokes from the server.
sample-obs-overlay.mp4
./nob testWarning
Rootless method gives you direct access to your keyboard.
To run rootless, follow these steps:
-
Create a udev rules file (for example,
/etc/udev/rules.d/90-keylogger.rules)echo "SUBSYSTEM==\"input\", OWNER=\"$USER\", MODE=\"0660\"" | sudo tee /etc/udev/rules.d/90-keylogger.rules > /dev/null
-
Reload udev rules
sudo udevadm control --reload-rules sudo udevadm trigger
