Skip to main content

qzkp

Quantum Zero-Knowledge Proof protocol with BB84 simulation and Aadhaar identity verification -- powered by Rust.

Install

pip install qzkp

Quick start

from qzkp import QZKPProtocol, QAadhaarProtocol, ServiceProvider, BB84QKD

# QZKP proof: same secret => valid
proto = QZKPProtocol("shared_secret", "shared_secret", 32, 0.025)
result = proto.run_protocol()
print(result["verification_status"])  # True
print(result["qber"])                 # ~0.02-0.09

# QZKP proof: different secrets => invalid
proto2 = QZKPProtocol("secret_a", "secret_b", 32, 0.025)
result2 = proto2.run_protocol()
print(result2["verification_status"])  # False

# Aadhaar authentication
aadhaar = QAadhaarProtocol(
    aadhaar_id="1234-5678-9012",
    master_secret="my_secret",
    attributes={"name": "Alice", "age": "25"},
)
challenge = aadhaar.request_authentication("Gov Portal", "identity_verification")
proof, qzkp_result = aadhaar.generate_proof(challenge)

verifier = ServiceProvider("Gov Portal")
print(verifier.verify_proof(proof))  # True

# BB84 key distribution
bb84 = BB84QKD(100, 0.02)
keys = bb84.generate_key()
print(keys["error_rate"])  # < 0.11

Reproducibility

All methods accept an optional seed parameter for deterministic results:

result = proto.run_protocol(seed=42)

License

MIT

Release files for qzkp 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for qzkp 0.1.0
File Size Uploaded
qzkp-0.1.0.tar.gz 19.9 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for qzkp 0.1.0
File
qzkp-0.1.0-cp313-cp313-win_amd64.whl CPython 3.13 CPython 3.13 Windows x86-64 Details
qzkp-0.1.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.13 CPython 3.13 Linux glibc 2.17+ x86-64 Details
qzkp-0.1.0-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl CPython 3.13 CPython 3.13 Linux glibc 2.17+ ARM64 Details
qzkp-0.1.0-cp313-cp313-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl CPython 3.13 CPython 3.13 macOS 10.12+ x86-64, macOS 10.12+ universal2 (ARM64, x86-64), macOS 11.0+ ARM64 Details

Total release size: 1.4 MB

Release files / qzkp-0.1.0.tar.gz

Download URL qzkp-0.1.0.tar.gz
Size 19.9 kB
Tags Source
SHA-256 checksum
How to use checksums
f691df3672bc34a16dae9db90c6109bdc7e683485616d74b86f8a38c5de28a0c
BLAKE2b-256 checksum
How to use checksums
3268ddb3ae56e019dc6896e192a4291290da590f74485f1b81502864c3b5241e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on May 19, 2026.

Transparency log

Release files / qzkp-0.1.0-cp313-cp313-win_amd64.whl

Download URL qzkp-0.1.0-cp313-cp313-win_amd64.whl
Size 179.4 kB
Tags CPython 3.13 Windows x86-64
SHA-256 checksum
How to use checksums
2ca850cb57ed32044375ee89f0a36bf8c5f660abd45361341d3617b9287fb5c9
BLAKE2b-256 checksum
How to use checksums
8ff1f005e627ccd1b936c4c3abd81ee26be0d3b500c17d0f9bbf15e73cb180d4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on May 19, 2026.

Transparency log

Release files / qzkp-0.1.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL qzkp-0.1.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 321.3 kB
Tags CPython 3.13 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
43027f1de1b86d47e8a53bda5e21dd0259918d1a77fc51782818a3c6a7357fcc
BLAKE2b-256 checksum
How to use checksums
243c38c720f010a466f32363bf6874520dac6bdbc3254ef2f78b2a89f9b1dfa2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on May 19, 2026.

Transparency log

Release files / qzkp-0.1.0-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl

Download URL qzkp-0.1.0-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Size 315.8 kB
Tags CPython 3.13 Linux glibc 2.17+ ARM64
SHA-256 checksum
How to use checksums
29a02e46c1976adf7bfceb536395f343533657098cca3ffa724784fcee25af74
BLAKE2b-256 checksum
How to use checksums
3ce34b9807bb74ae9c985a50bd75b290658606e88785f960b4ba3a0044dc08b3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on May 19, 2026.

Transparency log

Release files / qzkp-0.1.0-cp313-cp313-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl

Download URL qzkp-0.1.0-cp313-cp313-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl
Size 552.2 kB
Tags CPython 3.13 macOS 10.12+ universal2 (ARM64, x86-64) macOS 10.12+ x86-64 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
aeb70cc0f2253dbc609e29d5c8e40d34c8ecde3bb54741d695a3d19414d9d6ca
BLAKE2b-256 checksum
How to use checksums
4210b06590a3137c6c8f7f9667343db3819b6c07e7e5b7a51fbb6605e1f95feb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on May 19, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.0 This release

5 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page