Skip to main content
Log in

A novel image encryption based on hash function with only two-round diffusion process

  • Regular Paper
  • Published:
Multimedia Systems Aims and scope Submit manuscript

Abstract

In this paper, a novel algorithm for image encryption based on hash function is proposed. In our algorithm, a 512-bit long external secret key is used as the input value of the salsa20 hash function. First of all, the hash function is modified to generate a key stream which is more suitable for image encryption. Then the final encryption key stream is produced by correlating the key stream and plaintext resulting in both key sensitivity and plaintext sensitivity. This scheme can achieve high sensitivity, high complexity, and high security through only two rounds of diffusion process. In the first round of diffusion process, an original image is partitioned horizontally to an array which consists of 1,024 sections of size 8 × 8. In the second round, the same operation is applied vertically to the transpose of the obtained array. The main idea of the algorithm is to use the average of image data for encryption. To encrypt each section, the average of other sections is employed. The algorithm uses different averages when encrypting different input images (even with the same sequence based on hash function). This, in turn, will significantly increase the resistance of the cryptosystem against known/chosen-plaintext and differential attacks. It is demonstrated that the 2D correlation coefficients (CC), peak signal-to-noise ratio (PSNR), encryption quality (EQ), entropy, mean absolute error (MAE) and decryption quality can satisfy security and performance requirements (CC <0.002177, PSNR <8.4642, EQ >204.8, entropy >7.9974 and MAE >79.35). The number of pixel change rate (NPCR) analysis has revealed that when only one pixel of the plain-image is modified, almost all of the cipher pixels will change (NPCR >99.6125 %) and the unified average changing intensity is high (UACI >33.458 %). Moreover, our proposed algorithm is very sensitive with respect to small changes (e.g., modification of only one bit) in the external secret key (NPCR >99.65 %, UACI >33.55 %). It is shown that this algorithm yields better security performance in comparison to the results obtained from other algorithms.

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

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7
Fig. 8
Fig. 9
Fig. 10
Fig. 11
Fig. 12
Fig. 13
Fig. 14
Fig. 15

Similar content being viewed by others

References

  1. Chen, G., Mao, Y., Chui, C.K.: A symmetric image encryption scheme based on 3D chaotic cat maps. J. Chaos Solitons Fractals 21, 749–761 (2004)

    Article  MATH  MathSciNet  Google Scholar 

  2. Tong, X., Cui, M., Wang, Z.: A new feedback image encryption scheme based on perturbation with dynamical compound chaotic sequence cipher generator. J. Opt. Commun. 282, 2722–2728 (2009)

    Article  Google Scholar 

  3. Wei, X., Guo, L., Zhang, Q., Zhang, J., Lian, S.: A novel color image encryption algorithm based on DNA sequence operation and hyper-chaotic system. J. Syst. Softw. 85, 290–299 (2012)

    Article  Google Scholar 

  4. Alvarez, E., Fernandez, A., García, P., Jimenez, J., Marcano, A.: New approach to chaotic encryption. J. Phys. Lett. A 263, 373–375 (1999)

    Article  Google Scholar 

  5. Alvarez, G., Montoya, F., Romera, M., Pastor, G.: Cryptanalysis of a chaotic encryption system. J. Phys. Lett. A 276, 191–196 (2000)

    Article  MATH  MathSciNet  Google Scholar 

  6. Yen, J.C., Guo, J.I.: A new chaotic key-based design for image encryption and decryption. Proc. IEEE Int. Conf. Circuits Syst. 4, 49–52 (2000)

    Google Scholar 

  7. Li, S., Zheng, X.: Cryptanalysis of a chaotic image encryption method. Proc. IEEE Int. Symp. Circuits Syst. 2, 708–711 (2002)

    Google Scholar 

  8. Cheddad, A., Condell, J., Curran, K., Kevitt, P.M.: A hash-based image encryption algorithm. J. Opt. Commun. 283, 879–893 (2010)

    Article  Google Scholar 

  9. Rogaway, P., Shrimpton, T.: Cryptographic hash-function basics: definitions, implications, and separations for preimage resistance, second-preimage resistance, and collision resistance. J. Fast Softw. Encryption 3017, 371–388 (2004)

    Google Scholar 

  10. Wang, Y., Liao, X., Xiao, D., Wong, K.W.: One-way hash function construction based on 2D coupled map lattices. J. Inf. Sci. 178, 1391–1406 (2008)

    Article  MATH  Google Scholar 

  11. Sinha, A., Singh, K.: A technique for image encryption using digital signature. J. Opt. Commun. 218, 229–234 (2003)

    Article  Google Scholar 

  12. Encinas, L.H., Dominguez, A.P.: Comment on ‘A technique for image encryption using digital signature’. J. Opt. Commun. 268, 261–265 (2006)

    Article  Google Scholar 

  13. Seyedzade, S.M., Atani, R.E., Mirzakuchaki, S.: A novel image encryption algorithm based on hash function. In: Iranian Conference on Machine Vision and Image Processing, No. 5941167 (2010)

  14. Belkhouche, F., Qidwai, U.: Binary image encoding using one-dimensional chaotic map. In: Proceedings of the IEEE Annual Technical Conference, pp. 39–43 (2003)

  15. Bernstein, D.J.: Salsa20 specification. http://cr.yp.to/snuffle.html#xsalsa (2005)

  16. Borujeni, S.E., Eshghi, M.: Chaotic image encryption system using phase-magnitude transformation and pixel substitution. J. Telecommun. Syst. (2011). doi:10.1007/s11235-011-9458-8

  17. Seyedzadeh, S.M., Mirzakuchaki, S.: A fast color image encryption algorithm based on coupled two-dimensional piecewise chaotic map. J. Signal Process. 92, 1202–1215 (2012)

    Article  Google Scholar 

  18. Zhu, C.: A novel image encryption scheme based on improved hyperchaotic sequences. J. Opt. Commun. 285, 29–37 (2012)

    Article  Google Scholar 

  19. Kumar, A., Ghose, M.K.: Extended substitution–diffusion based image cipher using chaotic standard map. J. Commun. Nonlinear Sci. Numer. Simul. 16, 372–382 (2011)

    Article  MATH  MathSciNet  Google Scholar 

  20. Zhang, G., Liu, Q.: A novel image encryption method based on total shuffling scheme. J. Opt. Commun. 284, 2775–2780 (2011)

    Article  Google Scholar 

  21. Mazloom, S., Eftekhari-Moghadam, A.M.: Color image encryption based on coupled nonlinear chaotic map. J. Chaos Solitons Fractals 42, 1745–1754 (2009)

    Article  MATH  Google Scholar 

  22. Huang, C.K., Liao, C.W., Hsu, S.L., Jeng, Y.C.: Implementation of gray image encryption with pixel shuffling and gray-level encryption by single chaotic system. J. Telecommun. Syst. (2011). doi:10.1007/s11235-011-9461-0

  23. Akhshani, A., Behnia, S., Akhavan, A., Hassan, H.A., Hassan, Z.: A novel scheme for image encryption based on 2D piecewise chaotic maps. J. Opt. Commun. 283, 3259–3266 (2010)

    Article  Google Scholar 

  24. Sun, F., Liu, S., Li, Z., Lu, Z.: A novel image encryption scheme based on spatial chaos map. J. Chaos Solitons Fractals 38, 631–640 (2008)

    Article  MATH  MathSciNet  Google Scholar 

  25. Behnia, S., Akhshani, A., Ahadpour, S., Mahmodi, H., Akhavan, A.: A fast chaotic encryption scheme based on piecewise nonlinear chaotic maps. J. Phys. Lett. A 366, 391–396 (2007)

    Article  Google Scholar 

  26. Wang, Y., Wong, K.W., Liao, X., Chen, G.: A new chaos-based fast image encryption algorithm. J. Appl. Soft Comput. 11, 514–522 (2011)

    Article  Google Scholar 

  27. Kwok, H.S., Tang, W.K.S.: A fast image encryption system based on chaotic maps with finite precision representation. J. Chaos Solitons Fractals 32, 1518–1529 (2007)

    Article  MATH  MathSciNet  Google Scholar 

  28. Rhouma, R., Belghith, S.: Cryptanalysis of a new image encryption algorithm based on hyper-chaos. J. Phys. Lett. A 372, 5973–5978 (2008)

    Article  MATH  Google Scholar 

  29. Ge, X., Liu, F., Lu, B., Yang, C.: Improvement of Rhouma’s attacks on Gao algorithm. J. Phys. Lett. A 374, 1362–1367 (2010)

    Article  MATH  Google Scholar 

  30. Behnia, S., Akhshani, A., Mahmodi, H., Akhavan, A.: A novel algorithm for image encryption based on mixture of chaotic maps. J. Chaos Solitons Fractals 35, 408–419 (2008)

    Article  MATH  MathSciNet  Google Scholar 

  31. Zhang, Q., Guo, L., Wei, X.: Image encryption using DNA addition combining with chaotic maps. J. Math. Comput. Model. 52, 2028–2035 (2010)

    Article  MATH  MathSciNet  Google Scholar 

  32. Zhu, Z.L., Zhang, W., Wong, K.W., Yu, H.: A chaos-based symmetric image encryption scheme using a bit-level permutation. J. Inf. Sci. 181, 1171–1186 (2011)

    Article  Google Scholar 

  33. Gao, T., Chen, Z.: A new image encryption algorithm based on hyper-chaos. J. Phys. Lett. A 372, 394–400 (2008)

    Article  MATH  Google Scholar 

  34. Gao, T., Chen, Z.: Image encryption based on a new total shuffling algorithm. J. Chaos Solitons Fractals 38, 213–220 (2008)

    Article  MATH  MathSciNet  Google Scholar 

  35. Gao, H., Zhang, Y., Liang, S., Li, D.: A new chaotic algorithm for image encryption. J. Chaos Solitons Fractals 29, 393–399 (2006)

    Article  MATH  Google Scholar 

  36. Zhao, L., Adhikari, A., Xiao, D., Sakurai, K.: On the Security analysis of an image scrambling encryption of pixel bit and its improved scheme based on self-correlation encryption. J. Commun. Nonlinear Sci. Numer. Simulat. 17, 3303–3327 (2012)

    Article  MathSciNet  Google Scholar 

  37. Huang, X.: Image encryption algorithm using chaotic Chebyshev generator. J. Nonlinear Dyn. 67(4), 2411–2417 (2012)

    Article  Google Scholar 

  38. Francois, M., Grosges, T., Barchiesi, D., Erra, R.: A new image encryption scheme based on a chaotic function. J. Signal Process. Image Commun. 27, 249–259 (2012)

    Article  Google Scholar 

  39. Zhou, Y., Panetta, K., Agaian, S., Chen, C.L.P.: Image encryption using P-Fibonacci transform and decomposition. J. Opt. Commun. 285, 594–608 (2010)

    Article  Google Scholar 

  40. Lian, S., Sun, J., Wang, Z.: A block cipher based on a suitable use of the chaotic standard map. J. Chaos Solitons Fractals 26, 117–129 (2005)

    Article  MATH  Google Scholar 

  41. Chen, H.C., Guo, J.I., Huang, L.C., Yen, J.C.: Design and realization of a new signal security system for multimedia data transmission. J. EURASIP J. Appl. Signal Process. 13, 1291–1305 (2003)

    Article  Google Scholar 

  42. Yuen, C.H., Wong, K.W.: A chaos-based joint image compression and encryption scheme using DCT and SHA-1. J. Appl. Soft Comput. 11, 5092–5098 (2011)

    Article  Google Scholar 

  43. Cheddad, A., Condell, J., Curran, K., Kevitt, P.M.: A skin tone detection algorithm for an adaptive approach to steganography. J. Signal Process. 89, 2465–2478 (2009)

    Article  MATH  Google Scholar 

  44. Cheddad, A., Condell, J., Curran, K., Kevitt, P.M.: A secure and improved self-embedding algorithm to combat digital document forgery. J. Signal Process. 89, 2324–2332 (2009)

    Article  MATH  Google Scholar 

  45. Chen, T.S., Chen, J., Chen, J.G.: A simple and efficient watermark technique based on JPEG2000 Codec. Multimed. Syst. 10, 16–26 (2004)

    Article  Google Scholar 

  46. Chang, E.C., Kankanhalli, M.S., Guan, X., Huang, Z., Wu, Y.: Robust image authentication using content based compression. Multimed. Syst. 9, 121–130 (2003)

    Article  Google Scholar 

  47. Guo, H., Georganas, N.D.: A novel approach to digital image watermarking based on a generalized secret sharing scheme. Multimed. Syst. 9, 249–260 (2003)

    Article  Google Scholar 

  48. Pommer, A., Uhl, A.: Selective encryption of wavelet-packet encoded image data: efficiency and security. Multimed. Syst. 9, 279–287 (2003)

    Article  Google Scholar 

  49. Yeo, I.K., Kim, H.J.: Generalized patchwork algorithm for image watermarking. Multimed. Syst. 9, 261–265 (2003)

    Article  Google Scholar 

  50. Jiang, J., Armstrong, A., Feng, G.C.: Web-based image indexing and retrieval in JPEG compressed domain. Multimed. Syst. 9, 424–432 (2004)

    Article  Google Scholar 

  51. Norouzi, B., Mirzakuchaki, S., Seyedzadeh, S.M., Mosavi, M.R.: A simple, sensitive and secure image encryption algorithm based on hyper-chaotic system with only one round diffusion process. Multimed. Tools Appl. (2012). doi:10.1007/s11042-012-1292-9

  52. Seyedzadeh, S.M., Mirzakuchaki, S.: Image encryption scheme based on Choquet fuzzy integral with pseudo-random keystream generator. In: 11th International Symposium on Artificial Intelligence and Signal Processing (AISP), June 2011, pp. 101–106

  53. Seyedzadeh, S.M., Hashemi, Y.: Image encryption algorithm based on Choquet fuzzy integral with self-adaptive pseudo-random number generator. In: 11th International Conference on Intelligent Systems Design and Applications (ISDA), November 2011, pp. 642–647

  54. Menezes, A.J., van Oorschot, P.C., Vanstone, S.A.: Handbook of Applied Cryptography. CRC Press, Boca Raton (1997)

    MATH  Google Scholar 

  55. Goldreich, O.: Foundations of Cryptography. Weizmann Institute of Science, Rehovot (1995) (fragment of a book)

  56. Bernstein, D.: Salsa20 security. http://www.ecrypt.eu.org/stream/e2-salsa20.html

  57. Seyedzadeh, S.M., Moosavi, S.M.S., Mirzakuchaki, S.: Using self-adaptive coupled piecewise nonlinear chaotic map for color image encryption scheme. In: 19th Iranian Conference on Electrical Engineering, pp. 1–6 (2011)

  58. Neves, S.: Cryptography in GPUs. Master’s thesis, Universidade de Coimbra, Coimbra (2009). [Online]. http://eden.dei.uc.pt/~sneves/gpucrypto.pdf

  59. Mukherjee, P.: An overview of eSTREAM ciphers. [Online]. http://cs.au.dk/~pratyay/eSTREAM.pdf

  60. Mascagni, M., Chi, H.: Parallel linear congruential generators with Sophie–Germain moduli. Parallel Comput. 30(11), 1217–1231 (2004)

    Article  MathSciNet  Google Scholar 

  61. Wu, P., Huang, K.: Parallel use of multiplicative congruential random number generators. J. Parallel Comput. 175(1), 25–29 (2006)

    MATH  Google Scholar 

Download references

Acknowledgments

The authors would like to thank the Editor and the anonymous Referees for their valuable comments and suggestions to improve this paper.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Benyamin Norouzi.

Additional information

Communicated by M. Kankanhalli.

Rights and permissions

Reprints and permissions

About this article

Cite this article

Norouzi, B., Seyedzadeh, S.M., Mirzakuchaki, S. et al. A novel image encryption based on hash function with only two-round diffusion process. Multimedia Systems 20, 45–64 (2014). https://doi.org/10.1007/s00530-013-0314-4

Download citation

  • Received:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s00530-013-0314-4

Keywords

Navigation