124

PySecNet

A combination of "Python," "Security," and "Network."

PySecNet is an open-source project that provides a simplified implementation of SSL/TLS (Secure Sockets Layer/Transport Layer Security) in Python.

This project focuses on key cryptographic components such as AES encryption, SHA256 hashing, Diffie-Hellman key exchange and RSA encryption for secure communication.

Key Features

Cryptographic Primitives: Essential cryptographic primitives, ensuring data confidentiality, integrity, and authenticity.

Client-Server Architecture: A client-server architecture that allows secure communication between two parties.

SSL/TLS-like Functionality: SSL/TLS-like functionality to establish secure connections and protect data during transmission.

Handshake Protocol: A handshake protocol inspired by SSL/TLS to negotiate cryptographic parameters and exchange keys securely.

PKI System: A basic Public Key Infrastructure (PKI) system for certificate generation, signing, and verification.

Interactive Choice: Choose to run the client or server, interactively or via command-line arguments.

This project serves as a practical resource for understanding and implementing secure communication protocols in Python. Feel free to explore, and contribute to PySecNet.

setup

for windows

  • create a virtual environment
python -m venv venv
  • set execution policy
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope Process
  • activate the virtual environment
venv\Scripts\activate
  • run makefile
make install

for linux and mac

  • create a virtual environment
python3 -m venv venv
  • activate the virtual environment
source venv/bin/activate
  • run makefile
make install

How to Use

  • run main using make
make run
  • Select server and client in seperate terminal
  • Run 1 server and 2 clients

Client GUI