Cyclic Redundancy Check (CRC) is a computationally inexpensive function readily available in many high-speed networking devices, and thus it is used extensively as a hash function in many data-plane applications. However, CRC is not a true cryptographic hash function, and it leaves applications vulnerable to attack. While cryptographically secure hash functions exist, there is no fast and efficient implementation for such functions on high-speed programmable switches. In this paper, we introduce an implementation of a secure keyed hash function optimized for commodity programmable switches and capable of running entirely within the data plane. We implement HalfSipHash on the Barefoot Tofino switch by using dependency management schemes to conserve pipeline stages and slicing semantics for concise circular bit shift operations. We show that our efficient implementation performs 67 million, 90 million, 150 million, and 304 million hashes per second for 32-byte, 24-byte, 16-byte, and 8-byte input strings, respectively.
Mendeley helps you to discover research relevant for your work.
CITATION STYLE
Yoo, S., & Chen, X. (2021). Secure Keyed Hashing on Programmable Switches. In SPIN 2021 - Proceedings of the 2021 ACM SIGCOMM Workshop on Secure Programmable network INfrastructure (pp. 16–22). Association for Computing Machinery, Inc. https://doi.org/10.1145/3472873.3472881