Quantum cryptography offers possibilities to distribute keys securely by relying on the principles of quantum mechanics. This paper presents repeatable simulations of two well-known quantum key distribution protocols, BB84 and E91, and examines how eavesdropping, noise, and transmission losses affect their security. The simulations are carried out using the Qiskit framework. A theoretical analysis of the expected quantum bit error rate (QBER) under ideal conditions and during an intercept–resend attack is included. The Clauser–Horne–Shimony–Holt (CHSH) parameter is also evaluated for the entanglement-based protocol. The results show error rates close to zero without attack, an increase to about 25\% under eavesdropping, and reduced correlations in the presence of attacks or losses. For the E91 protocol, the CHSH parameter exceeds the classical bound (S >2) in the entangled scenario and drops below the classical limit (S <= 2) in the attack case.
Quantum cryptography offers possibilities to distribute keys securely by relying on the principles of quantum mechanics. This paper presents repeatable simulations of two well-known quantum key distribution protocols, BB84 and E91, and examines how eavesdropping, noise, and transmission losses affect their security. The simulations are carried out using the Qiskit framework. A theoretical analysis of the expected quantum bit error rate (QBER) under ideal conditions and during an intercept–resend attack is included. The Clauser–Horne–Shimony–Holt (CHSH) parameter is also evaluated for the entanglement-based protocol. The results show error rates close to zero without attack, an increase to about 25% under eavesdropping, and reduced correlations in the presence of attacks or losses. For the E91 protocol, the CHSH parameter exceeds the classical bound (S >2) in the entangled scenario and drops below the classical limit (S <= 2) in the attack case.
Entanglement-based quantum key distribution (QKD) uses Bell tests to assess correlations that may reveal disturbances in a shared quantum link. The Clauser–Horne–Shimony–Holt (CHSH) test measures these correlations; values above the classical limit of 2 indicate a Bell-inequality violation, proving entanglement between the two qubits. As such, the CHSH test is used to detect the presence of eavesdroppers, as any measurement on the qubits prior to reaching their destination will break entanglement. Using Qiskit Aer, the E91 protocol is simulated under the presence of four different kinds of noise as well as two intercept-and-resend eavesdropping strategies. Overall, the experiments show that both noise and eavesdropping cause noticeable decreases in the CHSH value. This shows the difficulties of eavesdropping detection under noise and informs the CHSH thresholds that should be set in noisy networks.
The rapid advancement of quantum computing poses a significant threat to classical cryptographic systems that form the backbone of modern digital security.Algorithms such as RSA and ECC, which rely on the computational difficulty of integer factorization and discrete logarithm problems, become vulnerable to quantum attacks, particularly Shor's algorithm.This project presents a comprehensive Quantum Key Distribution (QKD) Simulator that implements the BB84 and E91 protocols using IBM's Qiskit quantum computing framework, providing an interactive platform for understanding, simulating, and analyzing quantum-safe key exchange mechanisms.The simulator features a full-stack architecture with a FastAPI backend powered by Python and Qiskit for quantum circuit execution, and a React 19 frontend with TypeScript for interactive visualization.The BB84 protocol implementation supports configurable qubit counts, multiple measurement bases (Z, X, and Diagonal), Eve's intercept-resend attack simulation with adjustable interception rates, and Quantum Bit Error Rate (QBER) calculation with a security threshold of 8.5%.The E91 protocol implementation uses entangled Bell state pairs with configurable measurement angles, CHSH inequality violation testing for quantum security verification, and reverse gate anti-eavesdropping mechanisms.Additionally, the system includes an AES encryption module that uses quantum-generated keys from BB84 and E91 simulations to perform AES-128, AES-192, and AES-256 encryption, with privacy amplification for keys shorter than the required length.A simulation history system with SQLite and PostgreSQL support enables experiment tracking, comparison, and analysis.The project demonstrates the practical application of quantum mechanics principles to cryptographic security and serves as an educational tool for understanding the transition from classical to quantum-safe cryptography.
Quantum Key Distribution (QKD) provides information-theoretic security by exploiting the principles of quantum mechanics. Among QKD protocols, the BB84 scheme remains the most widely adopted for both theoretical research and practical implementation. A critical parameter determining the reliability and security of BB84 is the Quantum Bit Error Rate (QBER), which quantifies errors in the sifted key arising from channel noise or potential eavesdropping. This paper presents a systematic review and analysis of QBER within the BB84 protocol, examining its calculation, statistical estimation methods, and role in detecting eavesdropping activity. Simulation results, corroborated by reported experimental observations, reveal a near-linear relationship between eavesdropping intensity and QBER, with values approaching 25% under full intercept-resend attacks. Four confidence interval estimation methods, Wald, Wilson, Clopper-Pearson, and Hoeffding's inequality, are compared for robust QBER analysis in finite-key scenarios. Protocol enhancements, including decoy-state methods, hybrid cryptographic models, and quantum-resistant authentication, are discussed as mechanisms to mitigate errors and strengthen resilience across fiber, free-space, underwater, and satellite QKD systems. Open challenges in distinguishing noise-induced errors from malicious eavesdropping, and the role of adaptive error correction and machine-learning-assisted QBER estimation in future quantum networks, are identified as key directions for further research.
With the rapid development of quantum computing, traditional encryption techniques are expected to face serious security challenges in the near future. By depending on the principles of quantum physics rather than computing complexity, Quantum Key Distribution (QKD), and specifically the BB84 protocol, provides a radically new method of secure communication. In this project, an adaptive BB84-based framework is implemented and analyzed under realistic conditions, including channel noise and multiple eavesdropping strategies. The system integrates error correction, privacy amplification, finite-key analysis, and decoy-state mechanisms to reflect practical deployment scenarios. Three major attack models—intercept-resend, photon number splitting, and Trojan horse—are simulated to evaluate protocol robustness. The experimental results show that during normal communication the average Quantum Bit Error Rate (QBER) remains close to 3–4%, whereas the presence of active eavesdropping increases the QBER beyond the commonly accepted 11% threshold, resulting in protocol termination. Additional statistical testing under varying noise conditions confirms stable secret key generation and reliable detection of malicious interference. Overall, the proposed framework serves as a comprehensive simulation platform for studying the security behavior of BB84 in controlled experimental environments.
This paper investigates practical performances of the Ekert 91 protocol (E91) for future secure quantum networks. To seek future possible improvement, we investigate the important different principles of E91 and Bennet-Brasard (BB84) protocols. We perform a series of computer simulations to evaluate the performances of them and investigate the practical parameters. Furthermore, we simulate the E91 protocol using real-world practical scenarios involving eavesdropping and quantum channel errors. We present two scenarios: (1) the performance with eavesdropper interception under a perfect channel and (2) the performances with eavesdropper interception combined with channel errors. We found that: (i) the E91 protocol produces fewer keys compared to the BB84 protocol but does not require verification between two parties, (ii) the E91 protocol enhances security due to the utilization of Clauser, Horne, Shimony, and Holt (CHSH) inequality, and (iii) both eavesdropper and channel errors can impact the less production of keys obtained during the keys production.
Quantum Key Distribution (QKD) is increasingly recognized as a robust solution to the vulnerabilities posed by quantum computing to classical encryption systems. This paper presents a comprehensive investigation of the BB84 protocol, the foundational QKD scheme, through simulated quantum communication using IBM’s Qiskit framework. The study models quantum key exchange under both ideal and adversarial conditions, including channel noise and intercept-resend attacks. The Quantum Bit Error Rate (QBER) was measured as a function of noise intensity and eavesdropping, confirming that QBER increases predictably in compromised channels. A threshold of 11% QBER was used to determine the viability of secure key generation. Final key retention rates were analyzed across multiple channel scenarios, revealing BB84’s sensitivity to both photon loss and adversarial interference.\n\nSecurity vulnerabilities such as photon-number-splitting and detector blinding were assessed, and countermeasures including decoy-state protocols and authenticated classical channels were proposed. Four key performance graphs were generated to visualize system behavior under realistic operational conditions. The results support BB84’s theoretical advantage in ensuring information-theoretic security while acknowledging real-world limitations in transmission range and hardware reliability. The paper concludes by addressing future improvements in QKD systems, including satellite-based distribution, quantum repeaters, and device-independent implementations. Through simulation-driven analysis, this study validates BB84 as a practical defense against quantum-enabled attacks and underscores the need for continued development and standardization in post-quantum cryptographic infrastructure.