Papers
Topics
Authors
Recent
Gemini 2.5 Flash
Gemini 2.5 Flash
129 tokens/sec
GPT-4o
28 tokens/sec
Gemini 2.5 Pro Pro
42 tokens/sec
o3 Pro
4 tokens/sec
GPT-4.1 Pro
38 tokens/sec
DeepSeek R1 via Azure Pro
28 tokens/sec
2000 character limit reached

Generalized Power Attacks against Crypto Hardware using Long-Range Deep Learning (2306.07249v2)

Published 12 Jun 2023 in cs.CR

Abstract: To make cryptographic processors more resilient against side-channel attacks, engineers have developed various countermeasures. However, the effectiveness of these countermeasures is often uncertain, as it depends on the complex interplay between software and hardware. Assessing a countermeasure's effectiveness using profiling techniques or machine learning so far requires significant expertise and effort to be adapted to new targets which makes those assessments expensive. We argue that including cost-effective automated attacks will help chip design teams to quickly evaluate their countermeasures during the development phase, paving the way to more secure chips. In this paper, we lay the foundations toward such automated system by proposing GPAM, the first deep-learning system for power side-channel analysis that generalizes across multiple cryptographic algorithms, implementations, and side-channel countermeasures without the need for manual tuning or trace preprocessing. We demonstrate GPAM's capability by successfully attacking four hardened hardware-accelerated elliptic-curve digital-signature implementations. We showcase GPAM's ability to generalize across multiple algorithms by attacking a protected AES implementation and achieving comparable performance to state-of-the-art attacks, but without manual trace curation and within a limited budget. We release our data and models as an open-source contribution to allow the community to independently replicate our results and build on them.

Definition Search Book Streamline Icon: https://streamlinehq.com
References (87)
  1. TensorFlow: Large-scale machine learning on heterogeneous systems, 2015. Software available from tensorflow.org.
  2. Information theory-based evolution of neural networks for side-channel analysis. IACR Transactions on Cryptographic Hardware and Embedded Systems, 2023.
  3. Elie Bursztein et al. SCAAML: Side channel attacks assisted with machine learning, 2019.
  4. Mind the portability: A warriors guide through realistic profiled side-channel analysis. In Network and Distributed System Security Symposium, 2020.
  5. Is margin all you need? an extensive empirical study of active learning on tabular data. arXiv preprint arXiv:2210.03822, 2022.
  6. Hardened library for AES-128 encryption/decryption on ARM Cortex M4 architecture. https://github.com/ANSSI-FR/SecAESSTM32, 2020.
  7. A hacker guide to deep learning based side channel attacks. In DEF CON, editor, DEF CON 27, 2019.
  8. High order side-channel security for elliptic-curve implementations. IACR Transactions on Cryptographic Hardware and Embedded Systems, 2023.
  9. “Ooh Aah… Just a Little Bit”: a small amount of side channel can go a long way. In Cryptographic Hardware and Embedded Systems–CHES 2014: 16th International Workshop, Busan, South Korea, September 23-26, 2014. Proceedings 16. Springer, 2014.
  10. François Chollet et al. Keras. https://keras.io, 2015.
  11. Rich Caruana. Multitask learning. Springer, 1998.
  12. Deep learning to evaluate secure RSA implementations. IACR Transactions on Cryptographic Hardware and Embedded Systems, 2019.
  13. Convolutional neural networks with data augmentation against jitter-based countermeasures: Profiling attacks without pre-processing. In Cryptographic Hardware and Embedded Systems–CHES 2017: 19th International Conference, Taipei, Taiwan, September 25-28, 2017, Proceedings, 2017.
  14. Łukasz Chmielewski. Reassure (h2020 731591) ECC dataset, 2020.
  15. Francois Chollet. Deep learning with Python. Simon and Schuster, 2021.
  16. Efficient template attacks. In Smart Card Research and Advanced Applications: 12th International Conference, CARDIS 2013, Berlin, Germany, November 27-29, 2013. Revised Selected Papers 12, 2014.
  17. Ches 2023 challenge SMAesH challenge. https://raw.githubusercontent.com/simple-crypto/SMAesH-challenge-submissions/main/CHES2023_slides.pdf.
  18. Jean-Sébastien Coron. Resistance against differential power analysis for elliptic curve cryptosystems. In CHES, 1999.
  19. Template attacks. In Cryptographic Hardware and Embedded Systems, 2003.
  20. A simple and effective positional encoding for transformers, 2021.
  21. W2v-bert: Combining contrastive learning and masked language modeling for self-supervised speech pre-training, 2021.
  22. Cachequote: Efficiently recovering long-term secrets of sgx epid via cache attacks. IACR Transactions on Cryptographic Hardware and Embedded Systems, 2018.
  23. Reijndael: The advanced encryption standard. Dr. Dobb’s Journal: Software Tools for the Professional Programmer, 26(3):137–139, 2001.
  24. Study of deep learning techniques for side-channel analysis and introduction to ASCAD database. CoRR, 2018.
  25. A second look at the ascad databases. In International Workshop on Constructive Side-Channel Analysis and Secure Design, pages 75–99. Springer, 2022.
  26. Fido Alliance. FIDO 2.0: Key Attestation Format, 2015.
  27. Deep Learning. MIT Press, 2016. http://www.deeplearningbook.org.
  28. Subsampling and knowledge distillation on adversarial examples: New techniques for deep learning based side channel evaluations. Cryptology ePrint Archive, Report 2020/165, 2020. https://eprint.iacr.org/2020/165.
  29. Breaking masked implementations of the clyde-cipher by means of side-channel analysis - A report on the CHES challenge side-channel contest 2020. Cryptology ePrint Archive, Report 2022/471, 2022. https://eprint.iacr.org/2022/471.
  30. Lattice attacks against elliptic-curve signatures with blinded scalar multiplication. In Selected Areas in Cryptography (SAC), 2017.
  31. Estranet: An efficient shift-invariant transformer network for side-channel analysis. IACR Transactions on Cryptographic Hardware and Embedded Systems, 2024(1):336–374, 2024.
  32. Transformer quality in linear time. In International Conference on Machine Learning. PMLR, 2022.
  33. Deep neural network attribution methods for leakage analysis and symmetric key recovery. In Selected Areas in Cryptography, 2019.
  34. Lattice attacks on digital signature schemes. Designs, Codes and Cryptography, 2001.
  35. Encoding power traces as images for efficient side-channel analysis. In 2020 IEEE International Symposium on Hardware Oriented Security and Trust (HOST), pages 46–56, 2020.
  36. Clustering algorithms for non-profiled single-execution attacks on exponentiations. In CARDIS, 2014.
  37. Single-trace side-channel attacks on scalar multiplications with precomputations. In CARDIS, 2017.
  38. The elliptic curve digital signature algorithm (ECDSA). International journal of information security, 2001.
  39. Minerva: The curse of ECDSA nonces: Systematic analysis of lattice attacks on noisy leakage of bit-length of ECDSA nonces. IACR Transactions on Cryptographic Hardware and Embedded Systems, 2020.
  40. Differential power analysis. In Crypto, 1999.
  41. Scaling laws for neural language models, 2020.
  42. Paul C. Kocher. Timing attacks on implementations of Diffie-Hellman, RSA, DSS, and other systems. In Advances in Cryptology. Springer, 1996.
  43. A machine learning approach against a masked AES: Reaching the limit of side-channel attacks with a learning model. Journal of Cryptographic Engineering, 2015.
  44. Sgdr: Stochastic gradient descent with warm restarts. arXiv preprint arXiv:1608.03983, 2016.
  45. A convnet for the 2020s, 2022.
  46. Pay attention to raw traces: A deep learning architecture for end-to-end profiling attacks. IACR Transactions on Cryptographic Hardware and Embedded Systems, 2021.
  47. Deep learning side-channel analysis on large-scale traces - A case study on a polymorphic AES. Cryptology ePrint Archive, Report 2020/881, 2020. https://eprint.iacr.org/2020/881.
  48. Don’t learn what you already know: Grey-box modeling for profiling side-channel analysis against masking. Cryptology ePrint Archive, Report 2022/493, 2022. https://eprint.iacr.org/2022/493.
  49. Power analysis attacks: Revealing the secrets of smart cards. Springer Science & Business Media, 2008.
  50. Breaking cryptographic implementations using deep learning techniques. In Security, Privacy, and Applied Cryptography Engineering (SPACE), 2016.
  51. Side-channel analysis against ANSSI’s protected AES implementation on ARM: end-to-end attacks with multi-task learning. Journal of Cryptographic Engineering, 2023. https://eprint.iacr.org/2021/592.pdf.
  52. TPM-Fail: TPM meets timing and lattice attacks. In USENIX Security Symposium, 2020.
  53. Applying horizontal clustering side-channel attacks on embedded ecc implementations. In CARDIS, 2018.
  54. Attacking embedded ECC implementations through cmov side channels. In Roberto Avanzi and Howard M. Heys, editors, SAC 2016, volume 10532 of LNCS, pages 99–119. Springer, Heidelberg, August 2016.
  55. NewAE. NewAE Technology Inc. K82F target for CW308. https://www.newae.com/ufo-target-pages/NAE-CW308T-K82F.
  56. The insecurity of the digital signature algorithm with partially known nonces. Journal of Cryptology, 2002.
  57. Transformers without tears: Improving the normalization of self-attention. arXiv preprint arXiv:1910.05895, 2019.
  58. Kerastuner. https://github.com/keras-team/keras-tuner, 2019.
  59. Deep learning revolutionizing side channel cryptanalysis. DEF CON 27 https://www.youtube.com/watch?v=QXTricqAtPk, 2019.
  60. Keep it unsupervised: Horizontal attacks meet deep learning. IACR Transactions on Cryptographic Hardware and Embedded Systems, 2021.
  61. Strength in numbers: Improving generalization with ensembles in machine learning-based profiled side-channel analysis. IACR Transactions on Cryptographic Hardware and Embedded Systems, 2020.
  62. On the influence of optimizers in deep learning-based side-channel analysis. In Selected Areas in Cryptography, 2021.
  63. SoK: Deep learning-based physical side-channel analysis. ACM Computing Surveys, 2023.
  64. Electromagnetic analysis (EMA): Measures and counter-measures for smart cards. In Smart Card Programming and Security: International Conference on Research in Smart Cards, 2001.
  65. When similarities among devices are taken for granted: Another look at portability. In AFRICACRYPT, 2020.
  66. Side-channel attacks on blinded scalar multiplications revisited. In CARDIS, 2020.
  67. A side journey to titan. In USENIX Security Symposium, 2021.
  68. Sebastian Ruder. An overview of multi-task learning in deep neural networks, 2017.
  69. Swish: a self-gated activation function. arXiv preprint arXiv:1710.05941, 7(1):5, 2017.
  70. Lattice basis reduction: Improved practical algorithms and solving subset sum problems. Mathematical programming, 1994.
  71. Exponent blinding does not always lift (partial) SPA resistance to higher-level security. In ACNS, 2011.
  72. A unified framework for the analysis of side-channel key recovery attacks (extended version). Cryptology ePrint Archive, Report 2006/139, 2006. https://eprint.iacr.org/2006/139.
  73. Teledyne. Teledyne LeCroy WavePro 404HD-MS. https://teledynelecroy.com/oscilloscope/wavepro-hd-oscilloscope/wavepro-404hd-ms.
  74. The Sage Developers. SageMath, the Sage Mathematics Software System (Version 9.0), 2020. https://www.sagemath.org.
  75. Soft analytical side-channel attacks. In Palash Sarkar and Tetsu Iwata, editors, ASIACRYPT 2014, Part I, volume 8873 of LNCS, pages 282–296. Springer, Heidelberg, December 2014.
  76. Attention is all you need. Advances in neural information processing systems, 2017.
  77. Revisiting a methodology for efficient CNN architectures in profiling attacks. IACR Transactions on Cryptographic Hardware and Embedded Systems, 2020.
  78. Systematic side-channel analysis of Curve25519 with machine learning. Cryptology ePrint Archive, Report 2021/944, 2021. https://eprint.iacr.org/2021/944.
  79. Back to the basics: Seamless integration of side-channel pre-processing in deep neural networks. IEEE Transactions on Information Forensics and Security, 2021.
  80. Remove some noise: On pre-processing of side-channel measurements with autoencoders. IACR Transactions on Cryptographic Hardware and Embedded Systems, 2020.
  81. One trace is all it takes: Machine learning-based side-channel attack on EdDSA. In Security, Privacy, and Applied Cryptography Engineering: 9th International Conference, SPACE 2019, Gandhinagar, India, December 3–7, 2019, Proceedings 9, pages 86–105. Springer, 2019.
  82. I choose you: Automated hyperparameter tuning for deep learning-based side-channel analysis. IEEE Transactions on Emerging Topics in Computing, 2022.
  83. Smooth adversarial training. arXiv preprint arXiv:2006.14536, 2020.
  84. Methodology for efficient CNN architectures in profiling attacks. IACR Transactions on Cryptographic Hardware and Embedded Systems, 2020.
  85. Efficiency through diversity in ensemble models applied to side-channel attacks:–a case study on public-key algorithms–. IACR Transactions on Cryptographic Hardware and Embedded Systems, 2021.
  86. Deep learning mitigates but does not annihilate the need of aligned traces and a generalized ResNet model for side-channel attacks. Journal of Cryptographic Engineering, 2020.
  87. From homogeneous to heterogeneous: Leveraging deep learning based power analysis across devices. In ACM/IEEE Design Automation Conference (DAC), 2020.
Citations (4)

Summary

  • The paper introduces GPAM, a novel deep-learning architecture that automates power side-channel analysis across multiple cryptographic algorithms.
  • GPAM leverages temporal patchification and Transformer encoder blocks to efficiently process raw power traces without manual curation.
  • Experimental evaluations demonstrate competitive success against hardened AES and ECC implementations, prompting new directions in cryptographic security research.

Analyzing Cryptographic Hardware via Generalized Power Attacks with Long-Range Deep Learning

Elie Bursztein et al. introduce GPAM (Generalized Power Analysis Model), a sophisticated deep-learning architecture tailored for power side-channel analysis on cryptographic hardware. GPAM distinguishes itself by offering a unifying approach capable of analyzing multiple cryptographic algorithms and implementations, specifically targeting AES and ECC. The authors' research addresses the limited adaptability and high expertise requirements of current machine learning-based side-channel attacks, known as SCAAMLs.

Overview and Methodology

The paper emphasizes the vulnerability of cryptographic co-processors to side-channel attacks which exploit physical signal emissions to uncover secrets such as AES keys. Traditional countermeasures have focused on specific algorithmic protections, but they often fail to provide robust defenses in the face of varying attack vectors. GPAM aims to alleviate these adaptability issues by enabling profiling-based attacks that generalize automatically across implementations and algorithms without manual intervention.

The architecture of GPAM is crafted to bypass specific limitations identified in prior efforts. Notably, GPAM utilizes temporal patchification and Transformer encoder blocks to process extensive raw power traces effectively, avoiding the expensive preprocessing and expert intervention traditionally required. This approach efficiently tackles long-range data dependencies inherent in high-fidelity cryptographic traces. The multi-task learning framework facilitates the model's adaptability, allowing it to accommodate varied cryptographic algorithms and countermeasures in its evaluations.

Experimental Evaluation

Bursztein et al. validate GPAM's efficacy through extensive experimentation, demonstrating successful attacks on numerous hardened hardware-accelerated cryptographic implementations, such as AES-protected and ECDSA implementations. The model consistently showcases competitive performance with state-of-the-art attacks but operates without the requisite manual trace curation, demonstrating the inherent advantages of generalized models.

For ECC, GPAM achieved notable success across four hardware implementations with varying levels of security, accurately predicting crucial elements of protected computations. The tests revealed that predictions using intermediate variables considerably enhanced attack success under white-box conditions, underscoring the importance of multi-task learning. Even in challenging scenarios like CM3, GPAM identified leakages that were leveraged using lattice-based analysis to recover cryptographic secrets effectively.

Implications and Future Directions

The theoretical contributions of this investigation lie in establishing a methodological foundation for automated side-channel analyses. GPAM exemplifies the potential for machine learning architectures to offer scalable solutions against multiple cryptographic challenges, preserving analytical efficiency while providing robust attack models. The open-sourcing of GPAM's models and datasets further stimulates research reproducibility and advancements in cryptographic security.

While GPAM demonstrates high adaptability and effectiveness, it raises several compelling research questions for future exploration. Key among these is the development of countermeasures that sufficiently confound such generalized attacks. Moreover, techniques that better stabilize training against initialization influences and improve upon data efficiency remain as promising future directions. Additionally, expanding GPAM's capabilities to include other cryptographic algorithms and hardware designs could augment its applicability.

Overall, GPAM marks a pivotal step in evolving cryptographic attack strategies emphasizing automatic, scalable, and cross-implementation adaptability, encouraging a shift towards versatile solutions in the security domain.

Github Logo Streamline Icon: https://streamlinehq.com

GitHub

X Twitter Logo Streamline Icon: https://streamlinehq.com