Introducing Skein

Hash functions can be considered the main workforce of modern cryptography. Originally created to improve the efficiency of digital signatures, they are now used in virtually every part of the infrastructure where information is stored and exchanged. They can be found in cryptographic protocols, in the process of working with encryption keys, secure web connections, and even scanning for malware. Without hash functions, most of the things around us would simply not work.





The most common hash functions are SHA-0, SHA-1, and SHA-2, which includes SHA-256 and SHA-512. But by the end of the first decade of the twenty-first century, collision engineering methods were presented for each of them, which showed the presence of vulnerabilities in the algorithms and questioned the security of an electronic digital signature based on these hash functions. In this regard, the US National Institute of Standards and Technology (NIST) in 2007 announced a competition for a new cryptographic standard SHA-3.





Introduction

Armed with a list of requirements that included resistance to known attacks, minimizing memory usage, and optimizing for 64-bit processors, a team of scientists led by Bruce Schneier, author of the Twofish and Blowfish block ciphers, submitted their family of variable hash functions to a competition in 2008 bit depth Skein, which literally means "skein of yarn". Unfortunately for the authors, in 2012 the Skein algorithm lost to the faster and less vulnerable Keccak in the SHA-3 final. 





There are three parts to Skein:





  • configurable symmetric threefish block cipher





  • unique block of iterations (UBI)





  • optional argument system





Let's go in order.





Threefish

Threefish — , Skein. , , , Blowfish Twofish. Threefish - (sp-), , MIX, , XOR 2 64 . , 4 . tweak-.





Threefish TF(K, T, P),  





K





T — tweak-





P -





. Threefish 256, 512 1024 . , . : 72 80 256/512- 1024- . Tweak- 128 .





MIX (k1, k2) (g1, g2) , :





g1 = (k1 + k2) mod 264





g2 = (k2 ≪ R) ⊕ g1 , R — ,





UBI

Skein Threefish Unique Block Iteration. UBI . , , . F(S, A, T):





S Nb





A





T





A, , n Nb





F(S, A, T) :





H0=S





Hi+1 = TF(Hi ; T + min(NA; (i+1) Nb) + ai 2126 + bi (B2119+ 2127) ; Ai)Ai





a0=bk-1= 1, ai=bi=0, A 8 B=0, B=1





, . Skein , -.





: , , , . :





  • Configuration





  • Output





:





  • Public Key - , ,





  • Message -





  • Nonce -





  • Key - Skein MAC(message authentication code) KDF(key derivation function)





  • Personalization - ,





Skein

, . Skein, -, . UBI-. 3, UBI: , , . S = 0. Skein .





264 , , .





At the end, I would like to mention the areas of application of the Skein hash function. Using the system of additional arguments, it is possible to configure the algorithm for calculating the MAC or HMAC message authentication codes (hash-based MAC). Skein can also serve as a random number generator or as a mechanism for calculating a digital signature.








All Articles