Paper published in a book (Scientific congresses, symposiums and conference proceedings)
Optimized Implementation of SHA-512 for 16-bit MSP430 Microcontrollers
Franck, Christian; Groszschädl, Johann
2021 • In Ryan, Peter Y A; Toma, Cristian (Eds.) Innovative Security Solutions for Information Technology and Communications 14th International Conference, SECITC 2021, Virtual Event, November 25-26, 2021, Revised Selected Papers
[en] The enormous growth of the Internet of Things (IoT) in the recent past has fueled a strong demand for lightweight implementations of cryptosystems, i.e. implementations that are efficient enough to run on resource-limited devices like sensor nodes. However, most of today's widely-used cryptographic algorithms, including the AES or the SHA2 family of hash functions, were already designed some 20 years ago and did not take efficiency in restricted environments into account. In this paper, we introduce implementation options and software optimization techniques to reduce the execution time of SHA-512 on 16-bit MSP430 microcontrollers. These optimizations include a novel register allocation strategy for the 512-bit hash state, a fast "on-the-fly" message schedule with low RAM footprint, special pointer arithmetic to avoid the need to copy state words, as well as instruction sequences for multi-bit rotation of 64-bit operands. Thanks to the combination of all these optimization techniques, our hand-written MSP430 Assembler code for the SHA-512 compression function reaches an execution time of roughly 40.6k cycles on an MSP430F1611 microcontroller. Hashing a message of 1000 bytes takes slightly below 338k clock cycles, which corresponds to a hash rate of about 338 cycles/byte. This execution time sets a new speed record for hashing with 256 bits of security on a 16-bit platform and improves the time needed by the fastest C implementations by a factor of 2.3. In addition, our implementation is extremely small in terms of code size (roughly 2.1k bytes) and has a RAM footprint of only 390 bytes.
Disciplines :
Computer science
Author, co-author :
Franck, Christian ; University of Luxembourg > Faculty of Science, Technology and Medicine (FSTM) > Department of Computer Science (DCS)
Groszschädl, Johann ; University of Luxembourg > Faculty of Science, Technology and Medicine (FSTM) > Department of Computer Science (DCS)
External co-authors :
no
Language :
English
Title :
Optimized Implementation of SHA-512 for 16-bit MSP430 Microcontrollers
Publication date :
November 2021
Event name :
14th International Conference on Security for Information Technology and Communications (SecITC 2021)
Event place :
Bucharest, Romania
Event date :
from 25-11-2021 to 26-11-2021
Audience :
International
Main work title :
Innovative Security Solutions for Information Technology and Communications 14th International Conference, SECITC 2021, Virtual Event, November 25-26, 2021, Revised Selected Papers
Aranha, D.F., Gouvêa, C.P., Markmann, T., Wahby, R. S., Liao, K.: RELIC is an efficient library for cryptography. Source code (2020). http://github.com/relic-toolkit/relic
Cheng, H., Dinu, D., Großschädl, J.: Efficient implementation of the SHA-512 hash function for 8-Bit AVR microcontrollers. In: Lanet, J.-L., Toma, C. (eds.) SECITC 2018. LNCS, vol. 11359, pp. 273–287. Springer, Cham (2019). https://doi.org/10. 1007/978-3-030-12942-2 21
Damgård, I.B.: A design principle for hash functions. In: Brassard, G. (ed.) CRYPTO 1989. LNCS, vol. 435, pp. 416–427. Springer, New York (1990). https://doi.org/10.1007/0-387-34805-0 39
Evans, D.: The Internet of things: how the next evolution of the Internet is changing everything. Cisco IBSG white paper (2011) http://www.cisco.com/web/about/ac79/docs/innov/IoT IBSG 0411FINAL.pdf
Josefsson, S., Liusvaara, I.: Edwards-Curve Digital Signature Algorithm (EdDSA). Internet Research Task Force, Crypto Forum Research Group, RFC 8032 (2017)
Merkle, R.C.: A certified digital signature. In: Brassard, G. (ed.) CRYPTO 1989. LNCS, vol. 435, pp. 218–238. Springer, New York (1990). https://doi.org/10.1007/0-387-34805-0 21
National Institute of Standards and Technology (NIST). Secure Hash Standard (SHS). FIPS Publication 180-4 (2015) http://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.180-4.pdf
Davies-Meyer, B.P.: van Tilborg, H.C.A., Jajodia, S. (eds.) Encyclopedia of Cryptography and Security, 2nd (edn.), pp. 312–313. Springer, Boston, MA (2011). https://doi.org/10.1007/978-1-4419-5906-5 569
Stallings, W.: Cryptography and Network Security: Principles and Practice. Pearson, 7th (edn.) 2016
Texas Instruments Inc. MSP430 Family Architecture Guide and Module Library. TI literature number SLAUE10B (1996). http://www.ti.com/sc/docs/products/micro/msp430/userguid/ag 01.pdf
Weatherley, R., Fidler, E.: Noise-C library. Source code (2016). http://github.com/rweather/noise-c