Quantum Key Distribution: Modeling and Simulation through BB84 Protocol Using Python3
Abstract
:1. Introduction
- Design of a communication architecture model that takes advantage of quantum cryptography for enabling secure communication;
- Implementation and simulation of the BB84 protocol in python3;
- Analysis of QKD efficacy for secure communication.
2. Overview of Quantum Cryptography
Quantum Attacks
3. Related Work
4. Simulation Architectural Model and Implementation
4.1. Architectural Model
4.2. Implementation
Algorithm 1 Custom code simulation using the BB84 protocol. |
|
5. Results and Discussions
5.1. Communication Phase Results
5.2. Reconciliation Phase Results
5.3. Detection of Eavesdropper
5.4. Privacy Amplification Operations
6. Conclusions
Author Contributions
Funding
Institutional Review Board Statement
Informed Consent Statement
Conflicts of Interest
Abbreviations
IoT | Internet of Things |
V2I | Vehicle-to-Internet |
QKD | Quantum key distribution |
BB84 | Charles Bennett and Gilles Brassard’s protocol |
QB | Quantum box |
PG | Photon-based generator |
PE/D | Photon-based encoder/decoder |
PE | Photon-based encoder |
KG | Key-based generator |
PD | Photon-based decoder |
References
- Dahlberg, A.; Skrzypczyk, M.; Coopmans, T.; Wubben, L.; Rozpundefineddek, F.; Pompili, M.; Stolk, A.; Pawełczak, P.; Knegjens, R.; de Oliveira Filho, J.; et al. A Link Layer Protocol for Quantum Networks Axel. In Proceedings of the SIGCOMM’19: Proceedings of the ACM Special Interest Group on Data Communication, Beijing, China, 19–23 August 2019; pp. 159–173. [Google Scholar] [CrossRef] [Green Version]
- Wang, S.; Rohde, M.; Ali, A. Quantum Cryptography and Simulation: Tools and Techniques. In Proceedings of the ICCSP 2020: Proceedings of the 2020 4th International Conference on Cryptography, Security and Privacy, Nanjing, China, 10–12 January 2020; Association for Computing Machinery: New York, NY, USA, 2020; pp. 36–41. [Google Scholar] [CrossRef]
- Corcoles, A.D.; Kandala, A.; Javadi-Abhari, A.; McClure, D.T.; Cross, A.W.; Temme, K.; Nation, P.D.; Steffen, M.; Gambetta, J.M. Challenges and Opportunities of Near-Term Quantum Computing Systems. Proc. IEEE 2020, 108, 1338–1352. [Google Scholar] [CrossRef] [Green Version]
- 360researchreports. Global Quantum Key Distribution Qkd Market and Industry Reports. 2020. Available online: https://www.360researchreports.com/global-quantum-key-distribution-qkd-market-15068633 (accessed on 24 July 2022).
- Suresh, P.; Daniel, J.V.; Parthasarathy, V.; Aswathy, R.H. A state of the art review on the Internet of Things (IoT) history, technology and fields of deployment. In Proceedings of the 2014 International Conference on Science Engineering and Management Research (ICSEMR), Chennai, India, 27–29 November 2014; pp. 1–8. [Google Scholar] [CrossRef]
- Porzio, A. Quantum cryptography: Approaching communication security from a quantum perspective. In Proceedings of the 2014 Fotonica AEIT Italian Conference on Photonics Technologies, Naples, Italy, 12–14 May 2014; pp. 1–4. [Google Scholar] [CrossRef]
- Khan, E.; Meraj, S.; Khan, M.M. Security Analysis of QKD Protocols: Simulation and Comparison. In Proceedings of the 2020 17th International Bhurban Conference on Applied Sciences and Technology (IBCAST), Islamabad, Pakistan, 14–18 January 2020; pp. 383–388. [Google Scholar] [CrossRef]
- Mandal, B.; Chandra, S.; Alam, S.S.; Patra, S.S. A comparative and analytical study on symmetric key cryptography. In Proceedings of the 2014 International Conference on Electronics, Communication and Computational Engineering (ICECCE), Hosur, India, 17–18 November 2014; pp. 131–136. [Google Scholar] [CrossRef]
- Wu, C.L.; Hu, C.H. Computational Complexity Theoretical Analyses on Cryptographic Algorithms for Computer Security Application. In Proceedings of the 2012 Third International Conference on Innovations in Bio-Inspired Computing and Applications, Kaohsiung, Taiwan, 26–28 September 2012; pp. 307–311. [Google Scholar] [CrossRef]
- Simion, E.; Constantinescu, N.S. Complexity computations in code cracking problems. In Proceedings of the 24th International Spring Seminar on Electronics Technology. Concurrent Engineering in Electronic Packaging. ISSE 2001. Conference Proceedings (Cat. No.01EX492), Calimanesti-Caciulata, Romania, 5–9 May 2001; pp. 225–232. [Google Scholar] [CrossRef]
- Sharbaf, M.S. Quantum Cryptography: A New Generation of Information Technology Security System. In Proceedings of the 2009 Sixth International Conference on Information Technology: New Generations, Las Vegas, NV, USA, 27–29 April 2009; pp. 1644–1648. [Google Scholar] [CrossRef]
- Sharma, A.; Ojha, V.; Lenka, S. Security of entanglement based version of BB84 protocol for Quantum Cryptography. In Proceedings of the 2010 3rd International Conference on Computer Science and Information Technology, Chengdu, China, 9–11 July 2010; Volume 9, pp. 615–619. [Google Scholar] [CrossRef]
- Chen, C.Y.; Zeng, G.J.; Lin, F.J.; Chou, Y.H.; Chao, H.C. Quantum cryptography and its applications over the internet. IEEE Netw. 2015, 29, 64–69. [Google Scholar] [CrossRef]
- Brassard, G. Brief history of quantum cryptography: A personal perspective. In Proceedings of the IEEE Information Theory Workshop on Theory and Practice in Information-Theoretic Security, Awaji Island, Japan, 16–19 October 2005; pp. 19–23. [Google Scholar] [CrossRef] [Green Version]
- Coolman, R. What Is Quantum Mechanics? Scinerds. 2021. Available online: https://scinerds.tumblr.com/post/658075954562908161/what-is-quantum-mechanics-by-robert-coolman (accessed on 24 July 2022).
- Chris, D. The Famous Physicist Who Discovered Photons. Sciencing. 2019. Available online: https://sciencing.com/famous-physicist-discovered-photons-16203.html (accessed on 24 July 2022).
- Arthur, C. Famous Scientists. Arthur Compton–Biography, Facts and Pictures. 2018. Available online: https://www.famousscientists.org/arthur-compton (accessed on 24 July 2022).
- Djellab, R.; Benmohammed, M. Securing Encryption Key Distribution in WLAN via QKD. In Proceedings of the 2012 International Conference on Cyber-Enabled Distributed Computing and Knowledge Discovery, Sanya, China, 10–12 October 2012; pp. 160–165. [Google Scholar] [CrossRef]
- Shrivastava, A.; Singh, M. A security enhancement approach in quantum cryptography. In Proceedings of the 2012 5th International Conference on Computers and Devices for Communication (CODEC), Kolkata, India, 17–19 December 2012; pp. 1–4. [Google Scholar] [CrossRef]
- Pirandola, S.; Andersen, U.L.; Banchi, L.; Berta, M.; Bunandar, D.; Colbeck, R.; Englund, D.; Gehring, T.; Lupo, C.; Ottaviani, C.; et al. Advances in quantum cryptography. Adv. Opt. Photonics 2020, 12, 1012. [Google Scholar] [CrossRef] [Green Version]
- Kurochkin, V.L.; Neizvestny, I.G. Quantum cryptography. In Proceedings of the 2009 International Conference and Seminar on Micro/Nanotechnologies and Electron Devices, Novosibirsk, Russia, 1–6 July 2009; pp. 166–170. [Google Scholar] [CrossRef]
- Qu, Z.; Ordjevic, I.B. High-speed free-space optical continuous variable-quantum key distribution based on Kramers-Kronig scheme. IEEE Photonics J. 2018, 10, 1–7. [Google Scholar] [CrossRef]
- Sharma, R.D.; De, A. A new secure model for quantum key distribution protocol. In Proceedings of the 2011 6th International Conference on Industrial and Information Systems, Kandy, Sri Lanka, 16–19 August 2011; pp. 462–466. [Google Scholar] [CrossRef]
- Gyongyosi, L.; Imre, S. A Survey on quantum computing technology. Comput. Sci. Rev. 2019, 31, 51–71. [Google Scholar] [CrossRef]
- Oszmaniec, M.; Grudka, A.; Horodecki, M.; Wójcik, A. Creating a Superposition of Unknown Quantum States. Phys. Rev. Lett. 2016, 116, 110403. [Google Scholar] [CrossRef] [Green Version]
- Moody, D.; Alagic, G.; Apon, D.C.; Cooper, D.A.; Dang, Q.H.; Kelsey, J.M.; Liu, Y.K.; Miller, C.A.; Peralta, R.C.; Perlner, R.A.; et al. Status Report on the Second Round of the NIST Post-Quantum Cryptography Standardization Process; National Institute of Standards and Technology: Gaithersburg, MD, USA, 2020. [Google Scholar] [CrossRef]
- Wootters, W.K.; Zurek, W.H. A single quantum cannot be cloned. Nature 1982, 299, 802–803. [Google Scholar] [CrossRef]
- Vignesh, R.S.; Sudharssun, S.; Kumar, K.J. Limitations of Quantum and the Versatility of Classical Cryptography: A Comparative Study. In Proceedings of the 2009 Second International Conference on Environmental and Computer Science, Dubai, United Arab Emirates, 28–30 December 2009; pp. 333–337. [Google Scholar] [CrossRef]
- Cao, Y.; Zhao, Y.; Wang, Q.; Zhang, J.; Ng, S.X.; Hanzo, L. The Evolution of Quantum Key Distribution Networks: On the Road to the Qinternet. IEEE Commun. Surv. Tutor. 2022, 24, 839–894. [Google Scholar] [CrossRef]
- Shor, P.W.; Preskill, J. Simple Proof of Security of the BB84 Quantum Key Distribution Protocol. Phys. Rev. Lett. 2000, 85, 441–444. [Google Scholar] [CrossRef] [Green Version]
- Scarani, V.; Bechmann-Pasquinucci, H.; Cerf, N.J.; Dušek, M.; Lütkenhaus, N.; Peev, M. The security of practical quantum key distribution. Rev. Mod. Phys. 2009, 81, 1301–1350. [Google Scholar] [CrossRef] [Green Version]
- El Allati, A.; El Baz, M. Quantum key distribution using optical coherent states via amplitude damping. Opt. Quantum Electron. 2015, 47, 1035–1046. [Google Scholar] [CrossRef]
- Liu, S.; Lou, Y.; Chen, Y.; Jing, J. All-Optical Optimal N -to- M Quantum Cloning of Coherent States. Phys. Rev. Lett. 2021, 126, 60503. [Google Scholar] [CrossRef] [PubMed]
- Walton, A.; Ghesquiere, A.; Brumpton, G.; Jennings, D.; Varcoe, B. Thermal state quantum key distribution. J. Phys. B At. Mol. Opt. Phys. 2021, 54, 185501. [Google Scholar] [CrossRef]
- Phattaraworamet, T.; Youplao, P. Double Layers Quantum Key Distribution with Ability to Against PNS Attacks. In Proceedings of the 2019 2nd World Symposium on Communication Engineering, WSCE 2019, Nagoya, Japan, 20–23 December 2019; pp. 1–5. [Google Scholar] [CrossRef]
- Miroshnichenko, G.P.; Kozubov, A.V.; Gaidash, A.A.; Gleim, A.V.; Horoshko, D.B. Security of subcarrier wave quantum key distribution against the collective beam-splitting attack. Opt. Express 2018, 26, 11292. [Google Scholar] [CrossRef] [Green Version]
- Fei, Y.Y.; Meng, X.D.; Gao, M.; Ma, Z.; Wang, H. Exploiting wavelength-dependent beam splitter to attack the calibration of practical quantum key distribution systems. Optik 2018, 170, 368–375. [Google Scholar] [CrossRef]
- Pljonkin, A.; Petrov, D.; Sabantina, L.; Dakhkilgova, K. Nonclassical attack on a quantum keydistribution system. Entropy 2021, 23, 509. [Google Scholar] [CrossRef]
- Arteaga-díaz, P.; Cano, D.; Fernandez, V. Practical side-channel attack on free-space QKD systems with misaligned sources and countermeasures. IEEE Access 2022, 4, 1–11. [Google Scholar] [CrossRef]
- Jain, N.; Stiller, B.; Khan, I.; Elser, D.; Marquardt, C.; Leuchs, G. Attacks on practical quantum key distribution systems (and how to prevent them). Contemp. Phys. 2016, 57, 366–387. [Google Scholar] [CrossRef] [Green Version]
- Park, D.; Heo, D.; Kim, S.; Hong, S. Single Trace Attack on Key Reconciliation Process for Quantum Key Distribution. In Proceedings of the 2020 International Conference on Information and Communication Technology Convergence (ICTC), Jeju, Korea, 21–23 October 2020; Volume 2020, pp. 209–213. [Google Scholar] [CrossRef]
- Huang, J.Z.; Weedbrook, C.; Yin, Z.Q.; Wang, S.; Li, H.W.; Chen, W.; Guo, G.C.; Han, Z.F. Quantum hacking of a continuous-variable quantum-key-distribution system using a wavelength attack. Phys. Rev. A-At. Mol. Opt. Phys. 2013, 87, 062329. [Google Scholar] [CrossRef] [Green Version]
- Huang, J.Z.; Kunz-Jacques, S.; Jouguet, P.; Weedbrook, C.; Yin, Z.Q.; Wang, S.; Chen, W.; Guo, G.C.; Han, Z.F. Quantum hacking on quantum key distribution using homodyne detection. Phys. Rev. A-At. Mol. Opt. Phys. 2014, 89, 032304. [Google Scholar] [CrossRef] [Green Version]
- Wei, K.; Liu, H.; Ma, H.; Yang, X.; Zhang, Y.; Sun, Y.; Xiao, J.; Ji, Y. Feasible attack on detector-device-independent quantum key distribution. Sci. Rep. 2017, 7, 449. [Google Scholar] [CrossRef] [PubMed] [Green Version]
- Dervisevic, E.; Lauterbach, F.; Burdiak, P.; Rozhon, J.; Sl, M. Simulations of Denial of Service Attacks in Quantum Key Distribution Networks. In Proceedings of the 2022 XXVIII International Conference on Information, Communication and Automation Technologies (ICAT), Sarajevo, Bosnia and Herzegovina, 16–18 June 2022. [Google Scholar]
- Al-Mohammed, H.A.; Al-Ali, A.; Yaacoub, E.; Abualsaud, K.; Khattab, T. Detecting Attackers during Quantum Key Distribution in IoT Networks using Neural Networks. In Proceedings of the 2021 IEEE Globecom Workshops, GC Wkshps 2021, Madrid, Spain, 7–11 December 2021. [Google Scholar] [CrossRef]
- Zhao, W.; Shi, R.; Huang, D. Practical Security Analysis of Reference Pulses for Continuous-Variable Quantum Key Distribution. Sci. Rep. 2019, 9, 18155. [Google Scholar] [CrossRef] [PubMed]
- Pan, Y.; Zhang, L.; Huang, D. Practical security bounds against trojan horse attacks in continuous-variable quantum key distribution. Appl. Sci. 2020, 10, 7788. [Google Scholar] [CrossRef]
- Nandal, R.; Nandal, A.; Joshi, K.; Rathee, A.K. A Survey and Comparison of Some of the Most Prominent QKD Protocols (January 19 2021). SSRN Electron. J. 2021. [Google Scholar] [CrossRef]
- Morris, J.D.; Hodson, D.D.; Grimaila, M.R.; Jacques, D.R.; Baumgartner, G. Towards the modeling and simulation of quantum key distribution systems. Dep. Air Force Air Univ. 2014, 4, 47. [Google Scholar]
- Lardier, W.; Varo, Q.; Yan, J. Quantum-sim: An open-source co-simulation platform for quantum key distribution-based smart grid communications. In Proceedings of the 2019 IEEE International Conference on Communications, Control, and Computing Technologies for Smart Grids (SmartGridComm), Beijing, China, 21–23 October 2019; pp. 1–6. [Google Scholar] [CrossRef]
- Aji, A.; Jain, K.; Krishnan, P. A Survey of Quantum Key Distribution (QKD) Network Simulation Platforms. In Proceedings of the 2021 2nd Global Conference for Advancement in Technology (GCAT), Bangalore, India, 1–3 October 2021; Volume 16, pp. 1–8. [Google Scholar] [CrossRef]
- Quantum Key Distribution. 2022. Available online: https://qiskit.org/textbook/ch-algorithms/quantum-key-distribution.html (accessed on 24 July 2022).
- Jasim, O.K.; Abbas, S.; El-Horbaty, E.S.M.; Salem, A.B.M. Quantum Key Distribution: Simulation and Characterizations. Procedia Comput. Sci. 2015, 65, 701–710. [Google Scholar] [CrossRef] [Green Version]
- Buhari, A.; Zukarnain, Z.A.; Subramaniam, S.K.; Zainuddin, H.; Saharudin, S. An efficient modeling and simulation of quantum key distribution protocols using OptiSystem™. In Proceedings of the 2012 IEEE Symposium on Industrial Electronics and Applications, Bandung, Indonesia, 23–26 September 2012; pp. 84–89. [Google Scholar] [CrossRef]
- Kohnle, A.; Rizzoli, A. Interactive simulations for quantum key distribution. Eur. J. Phys. 2017, 38, 35403. [Google Scholar] [CrossRef] [Green Version]
- Chatterjee, R.; Joarder, K.; Chatterjee, S.; Sanders, B.C.; Sinha, U. Qkd S im, a simulation toolkit for quantum key distribution including imperfections: Performance analysis and demonstration of the B92 protocol using heralded photons. Phys. Rev. Appl. 2020, 14, 24036. [Google Scholar] [CrossRef]
- Mogos, G. Quantum key distribution—QKD simulation. In Proceedings of the 18th Conference of Quantum Information Processing, Sydney, Australia, 10–16 January 2015. [Google Scholar]
- Shajahan, R.; Nair, S.S. Simulation of BB84 Protocol over Classical Cryptography Channel for File Transfer. Int. Res. J. Eng. Technol. IRJET 2020, 7, 1029–1035. [Google Scholar]
- Sethia, A.; Banerjee, A. A MATLAB-based modelling and simulation package for DPS-QKD. J. Mod. Opt. 2022, 69, 392–402. [Google Scholar] [CrossRef]
- Kashyap, M.R. QKD Algorithm BB84 Protocol in Qiskit. Int. Res. J. Eng. Technol. 2020, 7, 2623–2626. [Google Scholar]
- Mina, M.Z.; Simion, E. A Scalable Simulation of the BB84 Protocol Involving Eavesdropping. In Innovative Security Solutions for Information Technology and Communications; Springer: Cham, Switzerland, 2021; pp. 91–109. [Google Scholar] [CrossRef]
- Fan-Yuan, G.J.; Chen, W.; Lu, F.Y.; Yin, Z.Q.; Wang, S.; Guo, G.C.; Han, Z.F. A universal simulating framework for quantum key distribution systems. Sci. China Inf. Sci. 2020, 63, 180504. [Google Scholar] [CrossRef]
- Kurochkin, V.L. Protocols for quantum cryptography. In Proceedings of the 2011 International Conference and Seminar of Young Specialists on Micro/Nanotechnologies and Electron Devices (EDM), Erlagol, Altai, 30 June–4 July 2011; pp. 114–115. [Google Scholar] [CrossRef]
- Swan, M.; Witte, F.; dos Santos, R.P. Quantum Information Science. IEEE Internet Comput. 2022, 26, 7–14. [Google Scholar] [CrossRef]
Parameters | Values |
---|---|
Qubit length (bits) | 256 |
Sender’s bit probability | 0.5 |
Receiver’s bit probability | 0.5 |
Attacker’s bit probability | 0.5 |
Error threshold | 0.11 |
Error detection sample length (bits) | 128 |
Parameters | Normal | Eavesdropping |
---|---|---|
Initial bits (bits) | 256 | 256 |
Final key length (bits) | 54 | 36 |
Error correction rate | 0.2421875 | 0.265625 |
Eavesdropper rate | 0.04296875 | 0.125 |
Party A, B bit probability | 0.5 | 0.5 |
Eve bit probability | 0.5 | 0.5 |
Base-mismatch (%) | 0.546875 | 0.5234375 |
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations. |
© 2022 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Adu-Kyere, A.; Nigussie, E.; Isoaho, J. Quantum Key Distribution: Modeling and Simulation through BB84 Protocol Using Python3. Sensors 2022, 22, 6284. https://doi.org/10.3390/s22166284
Adu-Kyere A, Nigussie E, Isoaho J. Quantum Key Distribution: Modeling and Simulation through BB84 Protocol Using Python3. Sensors. 2022; 22(16):6284. https://doi.org/10.3390/s22166284
Chicago/Turabian StyleAdu-Kyere, Akwasi, Ethiopia Nigussie, and Jouni Isoaho. 2022. "Quantum Key Distribution: Modeling and Simulation through BB84 Protocol Using Python3" Sensors 22, no. 16: 6284. https://doi.org/10.3390/s22166284