Python code for collecting and authenticating a user based on their keystroke patterns.
-
Using Docker:
docker build -t ucontacti/key-stroke:latest . docker run -p 5000:5000 -it ucontacti/key-stroke
-
Using Python(Make sure you are using python 3.6 or above):
pip install -r requirements.txt python app.py
Either way, the web page is accessible from localhost:5000
The code consists of the following parts
To collect data a web interface was implemented using Flask and keystrokes timing were sampled with the aid of Javascript event handlers.
feature_extractor the takes raw data and produces 3 different feature data set
Training was done using two major algorithms
- Classic Machine-Learning
- KNN
- SVM
- Neural Network (Pytorch)
The web platform also uses the model and performs a authentication using previous mentioned methods
The results of the authentication was over 90% and the detail report can be found here
- Saleh Daghigh - ucontacti
- Mahdi Paktinat
This project was done under the supervision of Dr. Michael Mock from Fraunhofer Institute.