Giter Site home page Giter Site logo

dove-shell's Introduction

Dove-shell

A pigeon-shell using MPI instead of socket

                                           ...   
                                           .` o `._ 
                                           :    .--'     
                                           ;   ( 
                                   ,,,,..,'     \
                .---------,:-"---"`<<<<<<<:      ;
                 `----lc.. `-._<<`",._,.'`       | 
                          `""-.`""- -'          ; 
                               '"..           ,/
                             ~"^"~^''-..,m_m-'`~"^"~"^
                                   ~"^"~"^"~"^~

Introduction

Dove-shell is like ssh but is not reactive and is one-to-one. In justification of this, one client connects to one server and one server only listens to one client. Moreover, you can not run command like cd or bash etc.

This project is for educational purpose that is to understand how ssh works, how to implement asymmetric encryption, how to implement remote shell over MPI.

Installation

For UNIX and GNU/LINUX users, you need mpi package. In case of Ubuntu, simply run sudo apt install mpi

For Windows users, you need MSMPI.

Python 3 setup pip3 install -r req.txt

Usage

dove_key_gen.py

Example:

python3 dove_key_gen.py --save_dir=rank0
python3 dove_key_gen.py --save_dir=rank1

This will create 2 folders. Each folders will have a pair of private and public keys.

dove_shell.py

Example:

mpirun -np 2 python3 dove_shell.py --config_file=config.json

About config.json

{
    "client_private_key" : "rank0/private.dove.txt",
    "server_public_key" : "rank1/public.dove.txt",
    "server_private_key" : "rank1/private.dove.txt",
    "client_public_key" : "rank0/public.dove.txt",
    "log_file" : "logs.txt"
}

Protocols

Dove-shell client-server protocol

dove_shell.png

Security protocol

encryption_protocol.png

Encryption protocol

decryption_protocol.png

Decryption protocol

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.