信息安全研究 ›› 2023, Vol. 9 ›› Issue (9): 832-.

• 学术论文 • 上一篇    下一篇

基于SIMD思想的SM4流水线优化设计

陈昆明1王佳慧2马利民1张伟1梁兆熙3   

  1. 1(北京信息科技大学计算机学院北京100101)
    2(国家信息中心信息与网络安全部北京100045)
    3(国家计算机网络应急技术处理协调中心北京100029)
    (1351007822@qq.com)

  • 出版日期:2023-09-17 发布日期:2023-10-04
  • 通讯作者: 张伟 博士,教授.主要研究方向为大数据处理、软硬件协同设计. zhwei@bistu.edu.cn
  • 作者简介:陈昆明 硕士.主要研究方向为软硬件协同设计、计算机体系结构. 1351007822@qq.com 王佳慧 博士,研究员.主要研究方向为云计算安全、大数据安全、云取证安全. wangjiahui@sic.gov.cn 马利民 博士,副教授.主要研究方向为网络安全协议、信息隐藏技术、大数据安全. markgoogle@qq.com 张伟 博士,教授.主要研究方向为大数据处理、软硬件协同设计. zhwei@bistu.edu.cn 梁兆熙 主要研究方向为密码算法的安全性分析. 15601055307@163.com

Optimization Design of SM4 Pipeline Based on SIMD Idea

  • Online:2023-09-17 Published:2023-10-04

摘要: SM4算法是我国商用密码标准,广泛应用于信息安全领域.由于SM4实现需要多次迭代和循环,所以SM4算法适合用硬件来实现.提出了一种基于ROM的并行S盒设计,面向SM4 ECB模式轮密钥更新的流水线结构,并且在此流水线基础上基于SIMD思想,对流水线结构进一步优化,减少了轮密钥生成的任务开销,实现了单轮密钥生成,多加解密数据流同时运算.提出的ROM流水线结构相比LUT流水线结构、BRAM流水线结构,降低了硬件资源使用,吞吐量分别提高了1.33倍和1.46倍;相比BRAM+寄存器流水线结构,节省了大量寄存器资源,而吞吐量没有明显下降.SIMD流水线结构当为1轮密钥生成4路加解密结构时,资源消耗仅为ROM流水线结构的2.5倍,效率提高了4倍.

关键词: SM4算法, 流水线结构, S盒设计, SIMD, 轮密钥优化

Abstract: SM4 algorithm is a Chinese commercial cryptography standard and is widely used in the field of information security. Since SM4 implementation requires multiple iterations and loops, so SM4 algorithm is suitable for hardware implementation, this paper proposes a ROMbased parallel Sbox design, for SM4 ECB mode round key update pipeline structure, and the pipeline structure is further optimized based on SIMD(single instruction multidata) ideas, reducing the task overhead of round key generation, realizing simultaneous operation of singleround key generation with multiencryption and decryption data flow. Compared with the LUT pipeline structure and BRAM pipeline structure, the ROM pipeline structure proposed in this paper can reduce the use of hardware resources, and the throughput (input and output) can be increased by 1.33 times and 1.46 times, respectively; compared with the BRAM+ register pipeline structure, a lot of register resources are saved, but the throughput is not significantly reduced. When the 4 road encryption and decryption structure is generated for the 1 round key, the resource consumption is only 2.5 times of the ROM pipeline structure, but the efficiency is increased by 4 times.

Key words: SM4 algorithm, pipeline structure, SBox design, SIMD, round key optimization

中图分类号: