Block ciphers

Threefish-1024

The large-block tweakable ARX cipher underlying the Skein hash

standard Safe API

About Threefish-1024

Threefish-1024 is one of 3 Threefish variants in the NextSSL registry, a block cipher. It uses a 128-byte (1,024-bit) key and a 128-byte (1,024-bit) block. It takes the parameter tweak. Its registry entry cites Skein 1.3 (Threefish). NextSSL lists it in the standard tier and exposes it through the safe API.

Overview

Threefish is a tweakable block cipher with 256-, 512- and 1024-bit blocks, designed as the core of the Skein hash function. It uses only 64-bit additions, rotations and XORs and accepts a 128-bit tweak alongside the key.

Threefish's MIX function adds two 64-bit words, rotates one by a constant and XORs it with the sum. Each round applies MIX to word pairs and then permutes the words; a subkey derived from the key and tweak is added every four rounds. Threefish-256 and -512 use 72 rounds, Threefish-1024 uses 80. The tweak makes each encryption a separate permutation, which Skein uses to encode block position and type.

NextSSL includes Threefish-256, Threefish-512 and Threefish-1024 as specified in Skein version 1.3. Its large block sizes and tweak input make it suitable for wide-block and tweakable constructions beyond hashing, though few have been standardised. The tweak is not a key, but it changes the permutation, and Skein uses it to encode position and block type.

History

2008–2008
  1. Threefish published

Security notes

No practical attacks on full Threefish are known; the best published results reach well under its full round count. It is rarely used outside Skein.

Typical uses

Building Skein and UBIWide-block or tweakable encryption research

Sizes

FieldBytesMeaning
key128Secret key
block128Block

Parameters

NameTypeRangeDefaultRequired
tweak bytes 16 – 16 — no

Parameters are passed as a string, for example nextssl_mac("hmac", "hash=sha512", …). Omitted parameters take their declared default.

Use it

from nextssl_demo import NextSSL

ns = NextSSL()              # safe API: safe and standard tiers
block = ns.call("blockcipher_encrypt", "threefish-1024", None, key, plaintext_block)[0]

Calls follow the NextSSL C ABI and its language bindings. Buffer sizes are validated against the sizes above.

Other Threefish variants

2

Frequently asked questions

What is Threefish-1024?

Threefish-1024 is a block cipher in the Threefish family. Threefish is a tweakable block cipher with 256-, 512- and 1024-bit blocks, designed as the core of the Skein hash function.

What are the Threefish-1024 sizes?

In NextSSL, Threefish-1024 uses: key 128 bytes, block 128 bytes.

Who designed Threefish-1024 and when?

Threefish-1024 belongs to the Threefish family, first published in 2008 by Niels Ferguson, Stefan Lucks, Bruce Schneier, Doug Whiting, Mihir Bellare, Tadayoshi Kohno, Jon Callas, Jesse Walker. Its origin: Skein 1.3 specification.

Which standards define Threefish-1024?

Threefish-1024 is referenced by Skein 1.3 (Threefish).

Is Threefish-1024 safe to use?

Threefish-1024 is in the standard tier. Standardised and sound. Reachable from the safe API. It can be called from the safe API.

What other Threefish variants are there?

NextSSL also registers threefish-256, threefish-512 in the Threefish family.