Code Monkey home page Code Monkey logo

data-collection's Introduction

release-date code-size tag Website Contributors Last-commit Languages MIT License


Logo

Mouse Behavioral Biometrics

Protection of Web applications with behavioral biometrics.
Data collection module
Visit Site · Report Bug

Table of Contents

About The Project

This project was created in the manner of preparing the bachelor's degree thesis on AGH University of Science and Technology, Department of Computer Science, Electronics and Telecommunications. The main idea is to collect data from user mouse, such as clicks, movement, etc.. The data will be used to feed a Machine Learning model to distinguish Web bots and humans on real commercial websites.

Built With

API:

  • Spring – main framework used for API
  • Maven – dependency Management
  • PostgreSQL – database
  • Docker – used to provide an easy way to deploy
  • JWT Token – used to authenticate users
  • OAuth2 – custom authorization server
  • Mockito –mocking framework for unit tests
  • JUnit - framework for unit tests

JS-Proxy:

  • Node – JavaScript runtime
  • Npm – package manager
  • Express – main framework used for proxy
  • Docker – used to provide an easy way to deploy
  • JWT Token – used to validate users
  • Redis –database to cache user token for efficiency
  • Jest - mocking/unit testing framework

Deployment:

Getting Started

To get a local copy up and running follow these simple steps.

Prerequisites

Things you need to install before running:

Java 8
Maven
Docker

Installation

  1. Clone the repo and change the directory:
git clone https://github.com/Mouse-BB-Team/Data-Collection.git
cd Data-Collection/

API:

  1. Change directory to api/ and build a java package:
cd api/
mvn clean compile package spring-boot:repackage
  1. Use docker-compose file to deploy api locally:
docker-compose -f docker-compose.yaml up

NOTE: you MUST configure your own env variables in docker-compose.yaml

JS-Proxy:

  1. Change directory to js-proxy/
  2. Run docker-compose file to deploy js-proxy:
docker-compose -f docker-compose.yaml up

NOTE: you MUST configure your own env variables in docker-compose.yaml to match previously set variables in API

Google Cloud Platform deployment:

If you want to deploy the app to GCP, use the yaml configuration files from k8s/ directory. Some additional settings are provided in the appendix at the end of document.

Usage

From now on you should be able to run the application in your Web browser on localhost:PORT (PORT env configured in docker files). You can signup/login into the site and the data will be collected in the background to the database.

License

Distributed under the MIT License. See LICENSE for more information.

Contact

Mail - [email protected]

Project Link: https://github.com/Mouse-BB-Team

Acknowledgements

Our thesis supervisor:

Authors

Appendix

Authorization sequence diagram:

JWT-obtaining-sequence

Kubernetes settings:

1. dc-api secret with env variables
DEFAULT_ADMIN_USERNAME: admin
DEFAULT_ADMIN_PASSWORD: admin
OAUTH2_CLIENTID: client_id
OAUTH2_CLIENTSECRET: password
OAUTH2_RSAPUBLICKEY: ssh-rsa_format
OAUTH2_RSAPRIVATEKEY: ssh-rsa_format
2. postgres secret with env variables
SPRING_DATASOURCE_URL: jdbc:postgresql://url/database
SPRING_DATASOURCE_USERNAME: admin
SPRING_DATASOURCE_PASSWORD: admin
3. static external IP address named web-static-ip:
gcloud compute addresses create web-static-ip --global

data-collection's People

Contributors

dependabot[bot] avatar kamkali avatar lothar1998 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.