BB84 Quantum Key Distribution Simulator
High-fidelity physical modeling of single-photon state preparation, eavesdropper interception analysis, and Devetak-Winter secret key rate distillation powered by IBM Qiskit 2.2 Aer.
Empirical Benchmark Presets
Pre-calibrated experimental configurations to observe key distribution boundaries.
Ideal Channel
Noiseless transmission with no eavesdropper. Basis reconciliation yields matching key without bit errors.
Intercept-Resend Attack
Eve measures qubits in random bases, inducing wave-function collapse and detectable error rates.
Depolarizing Channel
Simulates optical fiber attenuation and decoherence through Qiskit depolarizing noise channels.
Interactive 3-Layer System Architecture
Q-Sec separates presentation (Flask guest/auth endpoints), quantum domain operations (IBM Qiskit 2.2 Aer simulation), and data persistence (idempotent schema migrations) into cleanly decoupled tiers.
BB84 Quantum Key Distribution Protocol Pipeline
Information-theoretic security established by the Heisenberg Uncertainty Principle and the Quantum No-Cloning Theorem.
State Preparation
Alice generates classical bits $b_i \in \{0, 1\}$ and randomly encodes each into rectilinear ($+$) or diagonal ($\times$) single-photon states.
Quantum Channel
Photons traverse an optical fiber or free-space channel modeled via depolarizing noise $\mathcal{E}(\rho)$, vulnerable to eavesdropper intercept.
Projective Measurement
Bob independently selects random bases to measure incoming qubits. Sifting discards discordant bases over an authenticated classical channel.
Key Rate Distillation
QBER is evaluated on a sacrificed sample. If $\text{QBER} < 11\%$, Devetak-Winter bounds guarantee a distilled secret key rate $R_\infty \ge 1 - 2h(\text{QBER})$.