Abstract
Hash-based message authentication code (HMAC) is widely used in authentication and message integrity. As a Chinese hash algorithm, the SM3 algorithm is gradually winning domestic market value in China. The side channel security of HMAC based on SM3 (HMAC-SM3) is still to be evaluated, especially in hardware implementation, where only intermediate values stored in registers have apparent Hamming distance leakage. In addition, the algorithm structure of SM3 determines the difficulty in HMAC-SM3 side channel analysis. In this paper, a skillful bit-wise chosen-plaintext correlation power attack procedure is proposed for HMAC-SM3 hardware implementation. Real attack experiments on a field programmable gate array (FPGA) board have been performed. Experimental results show that we can recover the key from the hypothesis space of 2256 based on the proposed procedure.
Similar content being viewed by others
References
Belaïd S, Bettale L, Dottax E, et al., 2015. Differential power analysis of HMAC SHA-1 and HMAC SHA-2 in the Hamming weight model. In: Obaidat MS, Holzinger A, Filipe J (Eds.), E-Business and Telecommunications. Springer, Cham, p.363–379. https://doi.org/10.1007/978-3-319-25915-4_19
Bellare M, Canetti R, Krawczyk H, 1996. Keying hash functions for message authentication. Int Cryptology Conf on Advances in Cryptology, p.1–15. https://doi.org/10.1007/3-540-68697-5_1
Brier E, Clavier C, Olivier F, 2004. Correlation power analysis with a leakage model. In: Joye M, Quisquater JJ (Eds.), Cryptographic Hardware and Embedded Systems. Springer Berlin Heidelberg, p. 16–29. https://doi.org/10.1007/978-3-540-28632-5_2
Ding DW, Gao XW, 2012. Design and implementation of SM3 algorithm on FPGA. Microcomp Appl, 31(5): 26–28 (in Chinese). https://doi.org/10.3969/j.issn.1674-7720.2012.05.009
FIPS, 2002. The Keyed-Hash Message Authentication Code (HMAC). Federal Information Processing Standards Publication, Gaithersburg, MD, USA.
Guo LM, Wang LH, Liu D, et al., 2015. A chosen-plaintext differential power analysis attack on HMAC-SM3. 11 Int Conf on Computational Intelligence and Security, p.350–353. https://doi.org/10.1109/CIS.2015.91
Kocher P, Jaffe J, Jun B, 1999. Differential power analysis. In: Wiener M (Ed.), Advances in Cryptology. Springer Berlin Heidelberg, p.388–397. https://doi.org/10.1007/3-540-48405-l_25
Liu ZB, Ma Y, Jing JW, et al., 2011. Implementation of SM3 HASH function on FPGA. Netinfo Secur, 9: 191–193, 218 (in Chinese). https://doi.org/10.3969/j.issn.1671-1122.2011.09.059
Ma Y, Xia LN, Lin JQ, et al., 2012. Hardware performance optimization and evaluation of SM3 hash algorithm on FPGA. 14th Int Cryptology Conf on Information and Communications Security, p.105–118. https://doi.org/10.1007/978-3-642-34129-8_10
McEvoy R, Tunstall M, Murphy CC, et al., 2007. Differential power analysis of HMAC based on SHA-2, and countermeasures. 8th Int Conf on Information Security Applications, p.317–332. https://doi.org/10.1007/978-3-540-77535-5_23
Menezes A, van Oorschot PC, Vanstone S, 1996. Hash functions and data integrity. In: Handbook of Applied Cryptography. CRC Press, Boca Raton, USA, p.321–376.
Moradi A, Barenghi A, Kasper T, et al., 2011. On the vulnerability of FPGA bitstream encryption against power analysis attacks: extracting keys from Xilinx Virtex-II FPGAs. Proc 18th ACM Conf on Computer and Communications Security, p.111–124. https://doi.org/10.1145/2046707.2046722
Qu KG, An W, Wu LJ, et al., 2015. A novel masking scheme for SM3 based MAC. China Gommun, 12(6): 12–21. https://doi.org/10.1109/CC.2015.7122475
SCA, 2010. SM3 Cryptographic Hash Algorithm. State Cryptography Administration of China (in Chinese).
Sun W, Liu JR, Gu DW, et al., 2015. Research on power analysis against software-based and hardware-based cryptographic circuits. Int Conf on Computer Science and Communication Engineering, p. 1–8.
Tunstall M, Hanley N, McEvoy RP, et al., 2007. Correlation power analysis of large word sizes. IET Irish Signals and Systems Conf, p.13–14.
Wang XY, Yang XW, 2012. Optimization design and implementation of SM3 algorithm based on FPGA. Comput Eng, 38(6): 244–246 (in Chinese). https://doi.org/10.3969/j.issn.1000-3428.2012.06.081
Acknowledgments
The authors would like to thank Xu-guang GUAN, Tao SUN, Yong GU, et al., who are from State Key Laboratory of Cryptography, for the nice cooperation and meaningful suggestion.
Author information
Authors and Affiliations
Corresponding authors
Additional information
Project supported by the Major Program of the Ministry of Industry and Information Technology of China (No. 2017ZX01030301) and the Beijing Natural Science Foundation of China (No. 4162053)
Rights and permissions
About this article
Cite this article
Yuan, Y., Qu, Kg., Wu, Lj. et al. Correlation power attack on a message authentication code based on SM3. Frontiers Inf Technol Electronic Eng 20, 930–945 (2019). https://doi.org/10.1631/FITEE.1800312
Received:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1631/FITEE.1800312