Key derivation

Tuak

TUAK: the 3GPP Keccak-based alternative to MILENAGE for mobile authentication and key generation

unverified Root API only Copyleft feature
Unverified tier.

Source found and wired, correctness not fully proven. Root API only. Reach it with NextSSL(root=True) in Python or the nextssl_root_* functions in C.

About Tuak

Tuak is a key derivation function. It uses a 16–32-byte key, a 42–102-byte output, a 16-byte salt and a 32-byte info. It takes the parameters ck_len (default 16), ik_len (default 16), keccak_iterations (default 1) and res_len (default 4). Its registry entry cites 3GPP TS 35.231 and 3GPP TS 35.232. NextSSL lists it in the unverified tier and exposes it through the root API only (NextSSL(root=True) in Python, nextssl_root_* in C).

Overview

TUAK is a family of authentication and key generation functions specified by 3GPP as an alternative to MILENAGE, built on the Keccak permutation. NextSSL carries it as unverified, with variable key and output lengths.

TUAK derives authentication and session keys from a subscriber key using the Keccak permutation rather than AES. Its keys range from 16 to 32 bytes and its outputs from 42 to 102 bytes in the registry. Functions like this one are specified by 3GPP and run inside mobile operator networks, so they are rarely used outside that setting. Interoperability with a network requires following the specification exactly, including byte order and input layout.

NextSSL cites TS 35.231 and TS 35.232 for the algorithm. The registry records a range of output lengths rather than one fixed size. NextSSL keeps this entry for research and test vectors, and the registry does not record a review of its design. For general key derivation, HKDF or another standard function is the usual choice. Functions like this one are specified by 3GPP and run inside mobile operator networks, so they are rarely used outside that setting.

TUAK is standardised for 3GPP networks, and the archive tier is unverified because no independent review is recorded in NextSSL's data. Interoperability with a network requires following the specification exactly, including byte order and input layout. NextSSL keeps this entry for research and test vectors, and the registry does not record a review of its design. For general key derivation, HKDF or another standard function is the usual choice.

History

2013–2013
  1. TUAK published by ETSI SAGE

How it works

  1. The subscriber key and random challenge are absorbed into the Keccak state.
  2. The permutation runs for the configured number of rounds to derive the outputs.
  3. The outputs are cut to the length the network needs, such as keys and response values.

Security notes

The tier is unverified, so no security claim is made. Use it only where 3GPP specifies it.

Typical uses

3GPP authentication researchKeccak-based key derivation in mobile networksNot recommended as a general-purpose primitive

Sizes

FieldBytesMeaning
key16 – 32Secret key
out42 – 102Output
salt16Salt
info32Info

Parameters

NameTypeRangeDefaultRequired
ck_len u32 16 – 32 16 no
ik_len u32 16 – 32 16 no
keccak_iterations u32 1 – 1024 1 no
res_len u32 4 – 32 4 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

root = NextSSL(root=True)   # tier 'unverified' is reachable from the root API only
okm = root.call("kdf", "tuak", None, ikm, salt, b"context", 32)[0]

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

Frequently asked questions

What is Tuak?

Tuak is a KDF in the TUAK family. TUAK is a family of authentication and key generation functions specified by 3GPP as an alternative to MILENAGE, built on the Keccak permutation.

What are the Tuak sizes?

In NextSSL, Tuak uses: key 16 to 32 bytes, output 42 to 102 bytes.

Who designed Tuak and when?

Tuak belongs to the TUAK family, first published in 2013 by ETSI SAGE. Its origin: 3GPP TS 35.231.

Which standards define Tuak?

Tuak is referenced by 3GPP TS 35.231, 3GPP TS 35.232.

Is Tuak safe to use?

Tuak is in the unverified tier. Source found and wired, correctness not fully proven. Root API only. It is only reachable through the root API (NextSSL(root=True) in Python, nextssl_root_* in C).