This repository contains code proof of concept of a secure end to end communication scheme with Quantum Key Distribution using BB84 Protocol.
The idea is that, sharing secret key using BB84 protocol, derive key using HKDF, then perform encryption using the derived key with AES-GCM-256.
- Create a virtual environment:
python3 -m venv venv - Activate virtual environment:
source venv/bin/activate - Install dependency:
pip install -r requirements.txt - Run the program. For example, simulating qkd with 20 qubits without eavesdroping:
python3 main.py 20
Run the main.py script using Python. You must specify the number of qubits (num_bits) as the first argument.
Use --eavesdrop 1 if you want to activate eavesdropping.
if you want to run 20 qubit simulation with an eavesdropper, run: python3 main.py 20 --eavesdrop 1