Giter VIP home page Giter VIP logo

trivial_dsa's Introduction

Assignment - 2 SNS

Topic - Digital Signature Scheme

  • A simple client server model which performs a public key and elements transfer and then by using them and it performs the signature verification whenever a new signed messsage is provided with same elements.
  • Code is written in Python

Main code

Server.py

Multithreaded server which provides signature verification

Run Server
$ ./server.sh
Client.py

Client which provides message input, key generation and Signature generation support.

Run Client
$ ./server.sh [ IP address of server ]

Extra files

  • client.log - maintains a log session for client operations.
  • server.log - maintains a log session for server operations.

Modules

Dsa

Takes care of Public key, public elements generation, signing of the message and also verification.

  • modinv - calculates inverse modulo
  • extended_gcd - calculates extended gcd for two inputs
  • keyGeneration - generates public key elements and key.
  • signatureGeneration - generates signature over provided message
  • signatureVerification - performs verification over message signature with provided old values.
messageUtils

all forms of packet creation is done via this module

  • createPubKeyMsg - Packet for public key elements
  • createSignedMsg - Packet for message and signature details
  • createVerstatus - Packet for response of signature verification.
  • packMessage - Trivial serialization
  • unpackMessage - Trivial unserialization
minilogger

provides extremely basic logging capabilities

  • minilogger.writer - append or fresh log file operations
prime

module to perform all prime number calculcations

  • is_prime - test if prime or not
  • generate_prime_number - returns a prime number
  • generate_prime_candidate - limits the bound for prime number
  • prim_root - calculates primitive root of the prime number provided

trivial_dsa's People

Contributors

yinsain 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.