Skip to main content

A simple implementation of the BB84 quantum key distribution protocol.

Project description

bb84_crypto

I developed this package for crypto messagaing

it's easy to use. You would just need to install the package between your partner and go on :)

pip install bb84_crypto
from bb84_crypto import bb84_protocol, encrypt_message, decrypt_message

Here, generate a secret key using BB84 and share it with your partner

key = bb84_protocol(n=128)

Then, write your message and encrypt it, then also can be decrypted

message = "Hi Bob! Wassuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuup ?"
encrypted = encrypt_message(message, key)
decrypted = decrypt_message(encrypted, key)

Of course you would need to print the magic

print(f"Decrypted: {decrypted}")
Hi Bob! Wassuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuup ?

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bb84_crypto-1.0.0.tar.gz (3.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

bb84_crypto-1.0.0-py3-none-any.whl (3.5 kB view details)

Uploaded Python 3

File details

Details for the file bb84_crypto-1.0.0.tar.gz.

File metadata

  • Download URL: bb84_crypto-1.0.0.tar.gz
  • Upload date:
  • Size: 3.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for bb84_crypto-1.0.0.tar.gz
Algorithm Hash digest
SHA256 cb7e28d4f3e792725a6a4c69d26f12a024819154bb034982de16ce1c82784f33
MD5 6ad3eed524c78fa26995900c159e073c
BLAKE2b-256 35dc4df21f38392caffe4f8edc3de653b20787e4c1296d9fd8ca49579a46f0c8

See more details on using hashes here.

File details

Details for the file bb84_crypto-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: bb84_crypto-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 3.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for bb84_crypto-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 77c9bf38331bee18be9a0375f709b1b28d7b758f928884d6dda9658769a6c45e
MD5 1c01e9f018115a36620069c4850c73ae
BLAKE2b-256 4e1161781a52b8557e2a1c85ac87c202673640c35b3c51e1e9ce118a633b8ed2

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page