Two quantum protocols for secure hamming distance computation


Secure hamming distance computation occupies a vital position in secure multiparty computation, which allows two parties to jointly compute the hamming distance without disclosing their respective private information. There are a lot of significant applications of secure hamming distance computation in private similarity determination fields, such as in biometric identification and e-commerce. In this paper, we present two quantum protocols for secure hamming distance computation. Protocol I subtly makes use of quantum CNOT operator and quantum Shift operator, which are simple quantum operators, while Protocol II utilizes the features of measurement-device-independent quantum key distribution, which can solve the security loopholes in practical realizations due to the imperfection in the detectors. Both two protocols can ensure the fairness of two parties and a higher security than the classical related protocols.

This is a preview of subscription content, log in to check access.

Fig. 1


  1. 1.

    Yao, A.C.: Protocols for secure computations. In: 23rd Annual Symposium on Foundations of Computer Science, SFCS’08, pp. 160–164. IEEE (1982)

  2. 2.

    Goldreich, O., Micali, S., Wigderson, A.: How to play any mental game. In: Proceedings of the Nineteenth Annual ACM Symposium on Theory of Computing, pp. 218–229. ACM (1987)

  3. 3.

    Chaum, D., Crépeau, C., Damgard, I.: Multiparty unconditionally secure protocols. In: Proceedings of the Twentieth Annual ACM Symposium on Theory of Computing, pp. 11–19. ACM (1988)

  4. 4.

    Du, W., Atallah, M.J.: Secure multi-party computation problems and their applications: a review and open problems. In: Proceedings of the 2001 Workshop on New Security Paradigms, pp. 13–22. ACM (2001)

  5. 5.

    Bringer, J., Chabanne, H., Patey, A.: Shade: secure hamming distance computation from oblivious transfer. In: International Conference on Financial Cryptography and Data Security, pp. 164–176. Springer, Berlin, Heidelberg (2013)

  6. 6.

    Bringer, J., Chabanne, H., Favre, M. et al.: GSHADE: faster privacy-preserving distance computation and biometric identification. In: Proceedings of the 2nd ACM Workshop on Information Hiding and Multimedia Security, pp. 187–198. ACM (2014)

  7. 7.

    Kiraz, M.S., Genç, Z.A., Kardas, S.: Security and efficiency analysis of the Hamming distance computation protocol based on oblivious transfer. Secur. Commun. Netw. 8(18), 4123–4135 (2015)

    Article  Google Scholar 

  8. 8.

    Yasuda, M.: Secure Hamming distance computation for biometrics using ideal-lattice and ring-LWE homomorphic encryption. Inf. Secur. J. A Glob. Perspect. 26(2), 85–103 (2017)

    Article  Google Scholar 

  9. 9.

    Jarrous, A., Pinkas, B.: Secure Hamming distance based computation and its applications. In: ACNS, vol. 9, pp. 107–124 (2009)

    Google Scholar 

  10. 10.

    Osadchy, M., Pinkas, B., Jarrous, A. et al.: Scifi-a system for secure face identification. In: Proceedings of the 2010 IEEE Symposium on Security and Privacy (SP), pp. 239–254. IEEE (2010)

  11. 11.

    Huang, Y., Evans, D., Katz, J. et al.: Faster secure two-party computation using garbled circuits. In: USENIX Security Symposium, vol. 201(1). (2011)

  12. 12.

    Blanton, M., Gasti, P.: Secure and efficient protocols for iris and fingerprint identification. In: European Symposium on Research in Computer Security, pp. 190–209. Springer, Berlin, Heidelberg (2011)

    Google Scholar 

  13. 13.

    Kulkarni, R., Namboodiri, A.: Secure hamming distance based biometric authentication. In: 2013 International Conference on Biometrics (ICB), pp. 1–6. IEEE (2013)

  14. 14.

    Shor, P.W.: Algorithms for quantum computation: Discrete logarithms and factoring. In: Proceedings of the 35th Annual Symposium on Foundations of Computer Science, pp. 124–134. IEEE (1994)

  15. 15.

    Grover, L.K.: A fast quantum mechanical algorithm for database search. In: Proceedings of the Twenty-Eighth Annual ACM Symposium on Theory of Computing, pp. 212–219. ACM (1996)

  16. 16.

    Lo, H.K.: Insecurity of quantum secure computations. Phys. Rev. A 56(2), 1154 (1997)

    ADS  Article  Google Scholar 

  17. 17.

    Colbeck, R.: Impossibility of secure two-party classical computation. Phys. Rev. A 76(6), 062308 (2007)

    ADS  Article  Google Scholar 

  18. 18.

    Buhrman, H., Christandl, M., Schaffner, C.: Complete insecurity of quantum protocols for classical two-party computation. Phys. Rev. Lett. 109(16), 160501 (2012)

    ADS  Article  Google Scholar 

  19. 19.

    Nielsen, M., Chuang, I.: Quantum Computation and Quantum Information. Cambridge University Press, Cambridge (2000)

    Google Scholar 

  20. 20.

    Lo, H.K., Curty, M., Qi, B.: Measurement-device-independent quantum key distribution. Phys. Rev. Lett. 108(13), 130503 (2012)

    ADS  Article  Google Scholar 

  21. 21.

    Bennett, C.H., Brassard, G.: Quantum cryptography: public key distribution and coin tossing. In: International Conference on Computer System and Signal Processing, pp. 175–179. IEEE (1984)

  22. 22.

    Bennett, C.H.: Quantum cryptography using any two nonorthogonal states. Phys. Rev. Lett. 68(21), 3121 (1992)

    ADS  MathSciNet  Article  Google Scholar 

  23. 23.

    Wang, X.B.: Quantum key distribution with two-qubit quantum codes. Phys. Rev. Lett. 92(7), 077902 (2004)

    ADS  Article  Google Scholar 

Download references


This work was supported by National Natural Science Foundation of China (No. 61772001).

Author information



Corresponding author

Correspondence to Run-hua Shi.

Rights and permissions

Reprints and Permissions

About this article

Verify currency and authenticity via CrossMark

Cite this article

Peng, Z., Shi, R., Wang, P. et al. Two quantum protocols for secure hamming distance computation. Quantum Inf Process 18, 29 (2019).

Download citation


  • Secure multiparty computation
  • Hamming distance
  • Quantum unitary operator
  • Privacy