计算机科学技术学报 ›› 2021,Vol. 36 ›› Issue (5): 1102-1117.doi: 10.1007/s11390-021-0846-6

所属专题: Computer Architecture and Systems

• • 上一篇    下一篇

机器学习辅助的抗逻辑块加密密钥猜测攻击范式

Yi Zhong1, Jian-Hua Feng1, Senior Member, CCF, Xiao-Xin Cui1,*, Member, CCF, IEEE, and Xiao-Le Cui2, Member, CCF   

  1. 1 Institute of Microelectronics, Peking University, Beijing 100871, China;
    2 Key Laboratory of Integrated Microsystems, Peking University Shenzhen Graduate School, Shenzhen 518055, China
  • 收稿日期:2020-07-29 修回日期:2021-08-25 出版日期:2021-09-30 发布日期:2021-09-30
  • 作者简介:Yi Zhong received his B.S. degree in microelectronics from Peking University, Beijing, in 2018. He is currently a Ph.D. candidate in microelectronic and solid-state electronics at the Laboratory of SoC, Institute of Microelectronics, Peking University, Beijing. His current research interests include IC design on neuromorphic system and hardware security.
  • 基金资助:
    This work was supported by the 111 Project under Grant No. B18001, the National Key Research and Development Program of China under Grant No. 2018YFB2202605, the Guangdong Science and Technology Project of China under Grant No. 2019B010155002, and the National Natural Science Foundation of China under Grant No. 61672054.

Machine Learning Aided Key-Guessing Attack Paradigm Against Logic Block Encryption

Yi Zhong1, Jian-Hua Feng1, Senior Member, CCF, Xiao-Xin Cui1,*, Member, CCF, IEEE, and Xiao-Le Cui2, Member, CCF        

  1. 1 Institute of Microelectronics, Peking University, Beijing 100871, China;
    2 Key Laboratory of Integrated Microsystems, Peking University Shenzhen Graduate School, Shenzhen 518055, China
  • Received:2020-07-29 Revised:2021-08-25 Online:2021-09-30 Published:2021-09-30
  • About author:Yi Zhong received his B.S. degree in microelectronics from Peking University, Beijing, in 2018. He is currently a Ph.D. candidate in microelectronic and solid-state electronics at the Laboratory of SoC, Institute of Microelectronics, Peking University, Beijing. His current research interests include IC design on neuromorphic system and hardware security.
  • Supported by:
    This work was supported by the 111 Project under Grant No. B18001, the National Key Research and Development Program of China under Grant No. 2018YFB2202605, the Guangdong Science and Technology Project of China under Grant No. 2019B010155002, and the National Natural Science Foundation of China under Grant No. 61672054.

研究背景
在当前芯片设计流程中,硬件安全已经成为一个重要的考量因素。为此,逻辑块加密被提出并被采用为一种简单但有效的保护方法。通常,它以简单的加密门电路或是存储单元混淆在原始电路中,从而达到对恶意伪造、反向工程和硬件木马等攻击的防范。然而,随着机器学习技术的发展,这一被视为有效的防控手段愈来愈受到严厉的挑战。在旁路分析领域,机器学习被首先应用于攻击。攻击者利用功耗曲线在错误和正确密钥时不同的情况,借助机器学习工具分析内在的数学特征,从而达到破解的目的。另一方面,在逻辑分析领域,已有的方法包括基于错误率分析和布尔可满足性分析的方法等,这些方法有的已经设计了机器学习的基本概念,但尚未形成完备的机器学习攻击策略。
目的
本文旨在将机器学习引入到基于逻辑分析的密钥攻击领域,利用经典的机器学习算法如神经网络、线性回归等方法执行对密钥的破解。同时本文也力求探索机器学习破解逻辑加密的内在数学原理,发掘其暴露出的硬件安全问题,从而有针对性地改良硬件保护策略。
方法
本文提出了基于机器学习的逻辑攻击基本范式,即在攻击者拥有加密网表和激活电路的前提下,通过对两块电路施加相同的输入激励,收集不同的输出响应。由于两块电路输出的不同是由逻辑加密产生的,在输出端生成的向量蕴含了对加密密钥的潜在数学信息。因此我们使用经典的全连接神经网络来执行对加密网表的破解,通过将电路输出端、密钥端分别作为神经网络的输入层、输出层,可以构建在最大似然概率下的最佳拟合。我们将在激活电路下产生的正确输出向量送入训练好的神经网络,网络的输出结果就是对密钥的数学期望。这一系列数学期望随后被送入朴素贝叶斯分类器,将其归类为逻辑1和逻辑0,这样就确定了所有密钥的最终值。
结果
本文首先将机器学习攻击应用于C432电路作为示例,成功在3次迭代之后破解所有20位密钥。针对不同的加密策略,如随机加密,最大FI加密,异或同或门加密、多路选择器加密等,本文提出的攻击取得了不同的攻击效果,其中尤以最大FI多路器加密的攻击效果最好。我们将攻击范式应用于ISCAS’85/’89及ITC’99基准电路,尝试对组合和时序电路进行攻击,结果显示,在逐次迭代中,都能有部分密钥被破解,在短短3次迭代之内,所有电路能够破解20%~60%不等的密钥(取决于不同的电路拓扑结构)。
结论
本文提出了一种机器学习辅助的密钥猜测攻击范式,它作用于逻辑分析领域而非其他工作的旁路分析领域。在神经网络、贝叶斯分类器等机器学习工具的辅助下,该攻击范式能够在逐次迭代中,优先破解那些暴露信息最充分的密钥。由于相比传统暴力破解,我们使用了较为轻量的计算资源,因此能够大幅缩短用于破解密钥的时间。而且该攻击范式与传统逻辑分析攻击方法也能够兼容,结合起来可以充分加速密钥破解流程。此外,本文还分析了机器学习执行逻辑分析攻击的内在数学原理,指出皮尔森相关系数在暴露密钥信息上的重要作用。在未来的硬件防护策略中,设计者应该考虑尽可能消除引入的密钥端与电路输出端各种可能的统计相关性。

关键词: 硬件安全, 逻辑加密, 机器学习, 神经网络, 朴素贝叶斯分类器

Abstract: Hardware security remains as a major concern in the circuit design flow. Logic block based encryption has been widely adopted as a simple but effective protection method. In this paper, the potential threat arising from the rapidly developing field, i.e., machine learning, is researched. To illustrate the challenge, this work presents a standard attack paradigm, in which a three-layer neural network and a naive Bayes classifier are utilized to exemplify the key-guessing attack on logic encryption. Backed with validation results obtained from both combinational and sequential benchmarks, the presented attack scheme can specifically accelerate the decryption process of partial keys, which may serve as a new perspective to reveal the potential vulnerability for current anti-attack designs.

Key words: hardware security, logic encryption, machine learning, neural network, naive Bayes classifier

[1] Bhunia S, Tehranipoor M. Introduction to hardware security. In Hardware Security:A Hands-on Learning Approach (1st edition), Bhunia S, Tehranipoor M (eds.), Morgan Kaufmann, 2019, pp.1-20. DOI:10.1016/B978-0-12-812477-2.00006-X.
[2] Rajendran J, Sinanoglu O, Karri R. Regaining trust in VLSI design:Design-for-trust techniques. Proceedings of the IEEE, 2014, 102(8):1266-1282. DOI:10.1109/JPROC.2014.2332154.
[3] Hospodar G, Gierlichs B, Mulder E D, Verbauwhede I, Vandewalle J. Machine learning in side-channel analysis:A first study. Journal of Cryptographic Engineering, 2011, 1(4):Article No. 293. DOI:10.1007/s13389-011-0023-x.
[4] Gilmore R, Hanley N, O'Neill M. Neural network based attack on a masked implementation of AES. In Proc. the 2015 IEEE International Symposium on Hardware Oriented Security and Trust, May 2015, pp.106-111. DOI:10.1109/HST.2015.7140247.
[5] Maghrebi H, Portigliatti T, Prouff E. Breaking cryptographic implementations using deep learning techniques. In Proc. the 2016 International Conference on Security, Privacy, and Applied Cryptography Engineering, December 2016, pp.3-26. DOI:10.1007/978-3-319-49445-61.
[6] Das D, Golder A, Danial J, Ghosh S, Raychowdhury A, Sen S. X-DeepSCA:Cross-device deep learning side channel attack. In Proc. the 56th ACM/IEEE Design Automation Conference, June 2019, Article No. 134. DOI:10.1145/3316781.3317934.
[7] Das D, Danial J, Golder A, Ghosh S, Wdhury A R, Sen S. Deep learning side-channel attack resilient AES-256 using current domain signature attenuation in 65nm CMOS. In Proc. the 2020 IEEE Custom Integrated Circuits Conference, March 2020. DOI:10.1109/CICC48029.2020.9075889.
[8] Shan W W, Zhang S, Xu J M, Lu M Y, Shi L X, Yang J. Machine learning assisted side-channel-attack countermeasure and its application on a 28-nm AES circuit. IEEE Journal of Solid-State Circuits, 2020, 55(3):794-804. DOI:10.1109/JSSC.2019.2953855.
[9] Roy J A, Koushanfar F, Markov I L. EPIC:Ending piracy of integrated circuits. In Proc. the 2008 Design, Automation and Test in Europe, March 2008, pp.1069-1074. DOI:10.1109/DATE.2008.4484823.
[10] Rajendran J, Zhang H, Zhang C, Rose G S, Pino Y, Sinanoglu O, Karri R. Fault analysis-based logic encryption. IEEE Transactions on Computers, 2015, 64(2):410-424. DOI:10.1109/TC.2013.193.
[11] Pritika K, Vinodhini M. Logic encryption of combinational circuits. In Proc. the 3rd International Conference on Electronics, Materials Engineering & Nano-Technology, August 2019. DOI:10.1109/IEMENTech48150.2019.8981198.
[12] Kiryakina M A, Kuzmicheva S A, Ivanov M A. Encrypted PRNG by logic encryption. In Proc. the 2020 IEEE Conference of Russian Young Researchers in Electrical and Electronic Engineering, January 2020, pp.356-358. DOI:10.1109/EIConRus49466.2020.9038921.
[13] Karmakar R, Chatopadhyay S, Kapur R. Encrypt flip-flop:A novel logic encryption technique for sequential circuits. arXiv:1801.04961, 2018. https://arxiv.org/abs/1801.04961, January 2021.
[14] Si?ejkovi? D, Merchant F, Leupers R, Ascheid G, Kegreiss ?. Inter-Lock:Logic encryption for processor cores beyond module boundaries. In Proc. the 2019 IEEE European Test Symposium, May 2019. DOI:10.1109/ETS.2019.8791528.
[15] Karmakar R, Prasad N, Chattopadhyay S, Kapur R, Sengupta I. A new logic encryption strategy ensuring key interdependency. In Proc. the 30th International Conference on VLSI Design and the 16th International Conference on Embedded Systems, January 2017, pp.429-434. DOI:10.1109/VLSID.2017.29.
[16] Juretus K, Savidis I. Reduced overhead gate level logic encryption. In Proc. the 2016 International Great Lakes Symposium on VLSI, May 2016, pp.15-20. DOI:10.1145/2902961.2902972.
[17] Chen X M, Liu Q Y, Wang Y, Xu Q, Yang H Z. Lowoverhead implementation of logic encryption using gate replacement techniques. In Proc. the 18th International Symposium on Quality Electronic Design, March 2017, pp.257-263. DOI:10.1109/ISQED.2017.7918325.
[18] Yasin M, Mazumdar B, Ali S S, Sinanoglu O. Security analysis of logic encryption against the most effective sidechannel attack:DPA. In Proc. the 2015 IEEE International Symposium on Defect and Fault Tolerance in VLSI and Nanotechnology Systems, October 2015, pp.97-102. DOI:10.1109/DFT.2015.7315143.
[19] Yasin M, Rajendran J, Sinanoglu O, Karri R. On improving the security of logic locking. IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems, 2016, 35(9):1411-1424. DOI:10.1109/TCAD.2015.2511144.
[20] Lee Y W, Touba N A. Improving logic obfuscation via logic cone analysis. In Proc. the 16th Latin-American Test Symposium, March 2015. DOI:10.1109/LATW.2015.7102410.
[21] Plaza S M, Markov I L. Solving the third-shift problem in IC piracy with test-aware logic locking. IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems, 2015, 34(6):961-971. DOI:10.1109/TCAD.2015.2404876.
[22] Subramanyan P, Ray S, Malik S. Evaluating the security of logic encryption algorithms. In Proc. the 2015 IEEE International Symposium on Hardware Oriented Security and Trust, May 2015, pp.137-143. DOI:10.1109/HST.2015.7140252.
[23] Yasin M, Mazumdar B, Rajendran J, Sinanoglu O. SARLock:SAT attack resistant logic locking. In Proc. the 2016 IEEE International Symposium on Hardware Oriented Security and Trust, May 2016, pp.236-241. DOI:10.1109/HST.2016.7495588.
[24] Xie Y, Srivastava A. Anti-SAT:Mitigating SAT attack on logic locking. IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems, 2019, 38(2):199-207. DOI:10.1109/TCAD.2018.2801220.
[25] Chen Y C. Tree-based logic encryption for resisting SAT attack. In Proc. the 26th IEEE Asian Test Symposium, November 2017, pp.46-51. DOI:10.1109/ATS.2017.21.
[26] Shen Y Q, Rezaei A, Zhou H. SAT-based bit-flipping attack on logic encryptions. In Proc. the 2018 Design, Automation & Test in Europe Conference & Exhibition, March 2018, pp.629-632. DOI:10.23919/DATE.2018.8342086.
[27] Shen Y Q, Li Y, Kong S Y, Rezaei A, Zhou H. SigAttack:New high-level SAT-based attack on logic encryptions. In Proc. the 2019 Design, Automation & Test in Europe Conference & Exhibition, March 2019, pp.940-943. DOI:10.23919/DATE.2019.8714924.
[28] Kasarabada Y, Chen S Y, Vemuri R. On SATbased attacks on encrypted sequential logic circuits. In Proc. the 20th International Symposium on Quality Electronic Design, March 2019, pp.204-211. DOI:10.1109/ISQED.2019.8697421.
[29] Rajendran J, Pino Y, Sinanoglu O, Karri R. Logic encryption:A fault analysis perspective. In Proc. the 2012 Design, Automation & Test in Europe Conference & Exhibition, March 2012, pp.953-958. DOI:10.1109/DATE.2012.6176634.
[30] Karmakar R, Chattopadhyay S, Kapur R. Enhancing security of logic encryption using embedded key generation unit. In Proc. the 2017 International Test Conference in Asia (ITC-Asia), September 2017, pp.131-136. DOI:10.1109/ITC-ASIA.2017.8097127.
[31] Mobaraki S, Amirkhani A, Atani R E. A novel PUF based logic encryption technique to prevent SAT attacks and trojan insertion. In Proc. the 9th International Symposium on Telecommunications, December 2018, pp.507-513. DOI:10.1109/ISTEL.2018.8661086.
[1] 曹荣禹、曹逸轩、周干斌、罗平. 从长文档中提取深度可变的文档逻辑结构:方法、评估和应用[J]. 计算机科学技术学报, 2022, 37(3): 699-718.
[2] 魏华鹏, 邓盈盈, 唐帆, 潘兴甲, 董未名. 基于卷积神经网络和Transformer的视觉风格迁移的比较研究[J]. 计算机科学技术学报, 2022, 37(3): 601-614.
[3] 陈铮、方晓楠、张松海. 少纹理区域的局部单应性矩阵估计[J]. 计算机科学技术学报, 2022, 37(3): 615-625.
[4] 解晓政, 牛建伟, 刘雪峰, 李青锋, 王勇, 韩洁, 唐少杰. 基于卷积神经网络并融合边界信息的乳腺癌超声图像诊断[J]. 计算机科学技术学报, 2022, 37(2): 277-294.
[5] 王新峰、周翔、饶家华、张柱金、杨跃东. 基于迁移学习的DNA甲基化缺失数据补齐[J]. 计算机科学技术学报, 2022, 37(2): 320-329.
[6] 张鑫, 陆思源, 王水花, 余翔, 王甦菁, 姚仑, 潘毅, 张煜东. 通过新型深度学习架构诊断COVID-19肺炎[J]. 计算机科学技术学报, 2022, 37(2): 330-343.
[7] Geun Yong Kim, Joon-Young Paik, Yeongcheol Kim, and Eun-Sun Cho. 基于字节频率特征码的勒索病毒检测方法[J]. 计算机科学技术学报, 2022, 37(2): 423-442.
[8] 赵建喆, 王兴伟, 毛克明, 黄辰希, 苏昱恺, 李宇宸. 机器学习中基于相关差分隐私保护的多方数据发布方法[J]. 计算机科学技术学报, 2022, 37(1): 231-251.
[9] Dan-Hao Zhu, Xin-Yu Dai, Jia-Jun Chen. 预训练和学习:在图神经网络中保留全局信息[J]. 计算机科学技术学报, 2021, 36(6): 1420-1430.
[10] Feng Wang, Guo-Jie Luo, Guang-Yu Sun, Yu-Hao Wang, Di-Min Niu, Hong-Zhong Zheng. 在忆阻器中基于模式表示法的二值神经网络权重映射法[J]. 计算机科学技术学报, 2021, 36(5): 1155-1166.
[11] Shao-Jie Qiao, Guo-Ping Yang, Nan Han, Hao Chen, Fa-Liang Huang, Kun Yue, Yu-Gen Yi, Chang-An Yuan. 基数估计器:利用垂直扫描卷积神经网络处理SQL[J]. 计算机科学技术学报, 2021, 36(4): 762-777.
[12] Chen-Chen Sun, De-Rong Shen. 面向深度实体匹配的混合层次网络[J]. 计算机科学技术学报, 2021, 36(4): 822-838.
[13] Yang Liu, Ruili He, Xiaoqian Lv, Wei Wang, Xin Sun, Shengping Zhang. 婴儿的年龄和性别容易被识别吗?[J]. 计算机科学技术学报, 2021, 36(3): 508-519.
[14] Zhang-Jin Huang, Xiang-Xiang He, Fang-Jun Wang, Qing Shen. 基于卷积神经网络的实时多阶段斑马鱼头部姿态估计框架[J]. 计算机科学技术学报, 2021, 36(2): 434-444.
[15] Bo-Wei Zou, Rong-Tao Huang, Zeng-Zhuang Xu, Yu Hong, Guo-Dong Zhou. 基于对抗神经网络的跨语言实体关系分类[J]. 计算机科学技术学报, 2021, 36(1): 207-220.
Viewed
Full text


Abstract

Cited

  Shared   
  Discussed   
[1] 周笛;. A Recovery Technique for Distributed Communicating Process Systems[J]. , 1986, 1(2): 34 -43 .
[2] 陈世华;. On the Structure of Finite Automata of Which M Is an(Weak)Inverse with Delay τ[J]. , 1986, 1(2): 54 -59 .
[3] 李万学;. Almost Optimal Dynamic 2-3 Trees[J]. , 1986, 1(2): 60 -71 .
[4] 王选; 吕之敏; 汤玉海; 向阳;. A High Resolution Chinese Character Generator[J]. , 1986, 1(2): 1 -14 .
[5] 王建潮; 魏道政;. An Effective Test Generation Algorithm for Combinational Circuits[J]. , 1986, 1(4): 1 -16 .
[6] 陈肇雄; 高庆狮;. A Substitution Based Model for the Implementation of PROLOG——The Design and Implementation of LPROLOG[J]. , 1986, 1(4): 17 -26 .
[7] 黄河燕;. A Parallel Implementation Model of HPARLOG[J]. , 1986, 1(4): 27 -38 .
[8] 郑国梁; 李辉;. The Design and Implementation of the Syntax-Directed Editor Generator(SEG)[J]. , 1986, 1(4): 39 -48 .
[9] 黄学东; 蔡莲红; 方棣棠; 迟边进; 周立; 蒋力;. A Computer System for Chinese Character Speech Input[J]. , 1986, 1(4): 75 -83 .
[10] 许小曙;. Simplification of Multivalued Sequential SULM Network by Using Cascade Decomposition[J]. , 1986, 1(4): 84 -95 .
版权所有 © 《计算机科学技术学报》编辑部
本系统由北京玛格泰克科技发展有限公司设计开发 技术支持:support@magtech.com.cn
总访问量: