journal article·2020-02-24Open access

Memory Efficient Implementation of Modular Multiplication for 32-bit ARM Cortex-M4

Hwajeong Seo

Applied Sciences· Volume 10· Issue 4

Abstract

In this paper, we present scalable multi-precision multiplication implementation and scalable multi-precision squaring implementation for 32-bit ARM Cortex-M4 microcontrollers. For efficient computation and scalable functionality, we present optimized Multiplication and ACcumulation (MAC) techniques for the target microcontrollers. In particular, we present the 64-bit wise MAC operation with the Unsigned Long Multiply with Accumulate Accumulate (UMAAL) instruction. The MAC is used to perform column-wise multiplication/squaring (i.e., product-scanning) with general-purpose registers in an optimal way. Second, the squaring algorithm is further optimized through an efficient doubling routine together with an optimized product-scanning method. Finally, the proposed implementations achieved a very small memory footprint and high scalability to cover algorityms ranging from well-known public key cryptography (i.e., Rivest–Shamir–Adleman (RSA) and Elliptic Curve Cryptography (ECC)) to post-quantum cryptography (i.e., Supersingular Isogeny Key Encapsulation (SIKE)). All SIKE round 2 protocols were evaluated with the proposed modular reduction implementations. The results demonstrate that the scalable implementation can achieve the smallest code size together with a reasonable performance.
Source: crossref · Quality: baseline

Research context

OpenAlex topics: Cryptography and Residue Arithmetic · Coding theory and cryptography · Cryptography and Data Security

SciVX discovery tags are terminology-based. OpenAlex topics are source-provided classifications.

Affiliations

Department of IT convergence Engineering, Hansung University, 116 Samseong-Yoro-16-Gil Seongbuk-gu, Seoul 136-792, Korea

References (33)

Show source-provided references
1. Liu, Z., Seo, H., Großschädl, J., and Kim, H. (2014). Reverse product-scanning multiplication and squaring on 8-bit AVR processors. Information and Communications Security, Springer.10.1007/978-3-319-21966-0_12 ↗
2. Compact software implementation of public-key cryptography on MSP430X10.1145/3190855 ↗
3. Memory-efficient implementation of elliptic curve cryptography for the Internet-of-Things10.1109/TDSC.2018.2825449 ↗
4. Gura, N., Patel, A., Wander, A., Eberle, H., and Shantz, S.C. (2004). Comparing elliptic curve cryptography and RSA on 8-bit CPUs. Cryptographic Hardware and Embedded Systems—CHES 2004, Springer.10.1007/978-3-540-28632-5_9 ↗
5. Liu, A., and Ning, P. (2008, January 22–24). TinyECC: A configurable library for elliptic curve cryptography in wireless sensor networks. Proceedings of the International Conference on Information Processing in Sensor Networks (IPSN’08), St. Louis, MO, USA.10.1109/IPSN.2008.47 ↗
6. Aranha, D.F., and Gouvêa, C.P.L. (2020, February 18). RELIC is an Efficient LIbrary for Cryptography. Available online: https://github.com/relic-toolkit/relic.
7. Hutter, M., and Schwabe, P. (2013). NaCl on 8-bit AVR microcontrollers. Progress in Cryptology—AFRICACRYPT 2013, Springer.10.1007/978-3-642-38553-7_9 ↗
8. Liu, Z., Wenger, E., and Großschädl, J. (2014). MoTE–ECC: Energy-scalable elliptic curve cryptography for wireless sensor networks. Applied Cryptography and Network Security, Springer.10.1007/978-3-319-07536-5_22 ↗
9. De Groot, W. (2015). A Performance Study of X25519 on Cortex-M3 and M4. [Master’s Thesis, Eindhoven University of Technology].
10. De Santis, F., and Sigl, G. (2016, January 19–21). Towards side-channel protected X25519 on ARM Cortex-M4 processors. Proceedings of the SPEED-B—Software Performance Enhancement for Encryption and Decryption, and Benchmarking, Utrecht, The Netherlands.
11. Fujii, H., and Aranha, D.F. (2017). Curve25519 for the Cortex-M4 and beyond. Progress in Cryptology–LATINCRYPT 2017, Springer.
12. AuCPace: Efficient verifier-based PAKE protocol tailored for the IIoT
13. 18 Seconds to key exchange: Limitations of supersingular isogeny Diffie-Hellman on rmbedded devices
14. Seo, H., Jalali, A., and Azarderakhsh, R. (2019, January 25–27). SIKE round 2 speed record on ARM Cortex-M4. Proceedings of the The 18th International Conference on Cryptology And Network Security, Vienna, Austria.10.1007/978-3-030-31578-8_3 ↗
15. Moody, D. (2018). Let’s Get Ready to Rumble. The NIST PQC “Competition”, National Institute of Standards and Technology.
16. Exponentiation cryptosystems on the IBM PC10.1147/sj.294.0526 ↗
17. Hutter, M., and Wenger, E. (2011). Fast multi-precision multiplication for public-key cryptography on embedded microprocessors. Cryptographic Hardware and Embedded Systems–CHES 2011, Springer.10.1007/978-3-642-23951-9_30 ↗
18. Seo, H., and Kim, H. (2012). Multi-precision multiplication for public-key cryptography on embedded microprocessors. Information Security Applications, Springer.10.1007/978-3-642-35416-8_5 ↗
19. Improved multi-precision squaring for low-end RISC microcontrollers10.1016/j.jss.2012.06.074 ↗
20. Seo, H., Liu, Z., Choi, J., and Kim, H. (2013, January 7–10). Multi-precision squaring for public-key cryptography on embedded microprocessors. Proceedings of the Progress in Cryptology—INDOCRYPT 2013, Mumbai, India.10.1007/978-3-319-03515-4_15 ↗
21. Optimized Karatsuba squaring on 8-bit AVR processors10.1002/sec.1279 ↗
22. Kannwischer, M.J., Rijneveld, J., Schwabe, P., and Stoffelen, K. (2020, February 18). PQM4: Post-quantum crypto library for the ARM Cortex-M4. Available online: https://github.com/mupq/pqm4.
23. Towards quantum-resistant cryptosystems from supersingular elliptic curve isogenies
24. Azarderakhsh, R., Campagna, M., Costello, C., Feo, L.D., Hess, B., Jalali, A., Jao, D., Koziel, B., LaMacchia, B., and Longa, P. (2020, February 18). Supersingular Isogeny Key Encapsulation—Submission to the NIST’s Post-Quantum Cryptography Standardization Process, Available online: https://csrc.nist.gov/CSRC/media/Projects/Post-Quantum-Cryptography/documents/round-1/submissions/SIKE.zip.
25. Hofheinz, D., Hövelmanns, K., and Kiltz, E. (2017, January 12–15). A modular analysis of the Fujisaki-Okamoto transformation. Proceedings of the Theory of Cryptography—15th International Conference, Baltimore, MD, USA.10.1007/978-3-319-70500-2_12 ↗
26. Galbraith, S.D., Petit, C., Shani, B., and Ti, Y.B. (2016, January 4–8). On the Security of Supersingular Isogeny Cryptosystems. Proceedings of the Advances in Cryptology—ASIACRYPT 2016—22nd International Conference on the Theory and Application of Cryptology and Information Security, Hanoi, Vietnam.10.1007/978-3-662-53887-6_3 ↗
27. The National Institute of Standards and Technology (NIST) (2020, February 18). Post-Quantum Cryptography Standardization, 2017–2018, Available online: https://csrc.nist.gov/projects/post-quantum-cryptography/post-quantum-cryptography-standardization.
28. Azarderakhsh, R., Campagna, M., Costello, C., Feo, L.D., Hess, B., Jalali, A., Jao, D., Koziel, B., LaMacchia, B., and Longa, P. (2020, February 18). Supersingular Isogeny Key Encapsulation—Submission to the NIST’s Post-Quantum Cryptography Standardization Process, round 2, Available online: https://csrc.nist.gov/projects/post-quantum-cryptography/round-2-submissions/SIKE.zip.
29. Efficient algorithms for supersingular isogeny Diffie-Hellman
30. Modular multiplication without trial division10.1090/S0025-5718-1985-0777282-X ↗
31. Liu, Z., Longa, P., Pereira, G., Reparaz, O., and Seo, H. (2018). FourQ on embedded devices with strong countermeasures against side-channel attacks. IEEE Trans. Dependable Secure Comput.10.1109/TDSC.2018.2799844 ↗
32. Banik, S., Bogdanov, A., and Regazzoni, F. (2015, January 12–14). Exploring energy efficiency of lightweight block ciphers. Proceedings of the International Conference on Selected Areas in Cryptography, Sackville, Canada.10.1007/978-3-319-31301-6_10 ↗
33. Banik, S., Bogdanov, A., Regazzoni, F., Isobe, T., Hiwatari, H., and Akishita, T. (2016, January 3–5). Round gating for low energy block ciphers. Proceedings of the IEEE International Symposium on Hardware Oriented Security and Trust (HOST), McLean, VA, USA.10.1109/HST.2016.7495556 ↗