Sosemanuk
A software-oriented eSTREAM stream cipher combining an LFSR with Serpent S-boxes
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 Sosemanuk
Sosemanuk is a stream cipher. It uses a 16–32-byte key and a 16-byte nonce. 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
Sosemanuk is a software-oriented stream cipher from the eSTREAM project, designed by Cédric Berbain, Henri Gilbert and Alexander Maximov. It combines a linear feedback shift register with the S-boxes of the Serpent block cipher, and takes keys from 16 to 32 bytes with a 16-byte IV. NextSSL carries it as an unverified entry.
Sosemanuk is a stream cipher designed for the eSTREAM project, which selected stream ciphers for software and hardware profiles. Its design is a linear feedback shift register combined with a small finite-state machine that uses the S-boxes of the Serpent block cipher. The combination was chosen for fast software performance.
NextSSL records a key length of 16 to 32 bytes and a 16-byte IV. The archive treats the variant as unverified, which reflects NextSSL's review status. The eSTREAM portfolio is where most of the public analysis of this cipher sits, and the archive records no practical break of the full cipher.
The 128-bit key is a common choice in practice, though the cipher accepts keys up to 256 bits. A stream cipher must not reuse a key and IV pair, so the IV must be managed as carefully as the key.
History
2004–2008ECRYPT launches eSTREAM to find new stream ciphers
eSTREAM projectSosemanuk published by Cédric Berbain, Henri Gilbert, Alexander Maximov
34 designs submitted
eSTREAM projectFinal eSTREAM portfolio published
eSTREAM project
How it works
- The key and IV are loaded into the LFSR and the finite-state machine state.
- Each step updates the LFSR and the finite-state machine, using Serpent S-box outputs to mix the state.
- The keystream is XORed with the plaintext, and the receiver regenerates it from the same key and IV.
Security notes
Unverified in NextSSL. The archive records no practical break of the full cipher. Keys and IVs must never repeat as a pair.
Typical uses
Sizes
| Field | Bytes | Meaning |
|---|---|---|
| key | 16 – 32 | Secret key |
| nonce | 16 | Nonce / IV |
Use it
from nextssl_demo import NextSSL
root = NextSSL(root=True) # tier 'unverified' is reachable from the root API only
ct = root.call("stream_apply", "sosemanuk", None, key, nonce, b"secret")[0] # same call decrypts
nextssl_root_stream_apply("sosemanuk", NULL, key, nonce, data, out);
use nextssl_core::Params;
use nextssl_registry::{self as reg, Policy};
let alg = reg::new_streamcipher_in(reg::all(), Policy::Any, "sosemanuk", &Params::new())?;
let ct = alg.apply_keystream(&key, &nonce, b"secret")?;
Calls follow the NextSSL C ABI and its language bindings. Buffer sizes are validated against the sizes above.
More stream ciphers
All 37Frequently asked questions
What is Sosemanuk?
Sosemanuk is a stream cipher in the Sosemanuk family. Sosemanuk is a software-oriented stream cipher from the eSTREAM project, designed by Cédric Berbain, Henri Gilbert and Alexander Maximov.
What are the Sosemanuk sizes?
In NextSSL, Sosemanuk uses: key 16 to 32 bytes, nonce 16 bytes.
Who designed Sosemanuk and when?
Sosemanuk belongs to the Sosemanuk family, first published in 2005 by Cédric Berbain, Henri Gilbert, Alexander Maximov. Its origin: eSTREAM project, software profile.
Is Sosemanuk safe to use?
Sosemanuk 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).
Related families
ARX stream cipher with a one-time Poly1305 MAC; fast and constant-time in software
ChaChaBernstein's ARX stream cipher; ChaCha20 secures much of today's TLS, SSH and VPN traffic
RabbitA high-speed stream cipher in the eSTREAM software portfolio, specified in RFC 4503
SEAL 3.0A 1990s software-oriented stream cipher by Rogaway and Coppersmith with a 160-bit key
SNOW 2.0A word-oriented LFSR stream cipher, standardised in ISO/IEC 18033-4 and parent of SNOW 3G
TriviumA minimal hardware stream cipher in the eSTREAM portfolio, standardised in ISO/IEC 29192-3