Serpent (cipher)
Serpent is a symmetric key block cipher that was a finalist in the Advanced Encryption Standard (AES) contest, in which it ranked second to Rijndael.[src] Serpent was designed by Ross Anderson, Eli Biham, and Lars Knudsen.[src] Like other AES submissions, Serpent has a block size of 128 bits and supports a key size of 128, 192, or 256 bits.[src] The cipher is a 32-round substitution–permutation network operating on a block of four 32-bit words.[src] Each round applies one of eight 4-bit to 4-bit S-boxes 32 times in parallel.[src] Serpent was designed so that all operations can be executed in parallel, using 32 bit slices.[src] This maximizes parallelism but also allows use of the extensive cryptanalysis work performed on DES.[src] Serpent took a conservative approach to security, opting for a large security margin: the designers deemed 16 rounds to be sufficient against known types of attack but specified 32 rounds as insurance against future discoveries in cryptanalysis.[src] The official NIST report on AES competition classified Serpent as having a high security margin like MARS and Twofish and in contrast to the adequate security margin of RC6 and Rijndael (currently AES).…[src]
Serpent is a symmetric key block cipher that was a finalist in the Advanced Encryption Standard (AES) contest, in which it ranked second to Rijndael.[src] Serpent was designed by Ross Anderson, Eli Biham, and Lars Knudsen.[src] Like other AES submissions, Serpent has a block size of 128 bits and supports a key size of 128, 192, or 256 bits.[src] The cipher is a 32-round substitution–permutation network operating on a block of four 32-bit words.[src] Each round applies one of eight 4-bit to 4-bit S-boxes 32 times in parallel.[src] Serpent was designed so that all operations can be executed in parallel, using 32 bit slices.[src] This maximizes parallelism but also allows use of the extensive cryptanalysis work performed on DES.[src] Serpent took a conservative approach to security, opting for a large security margin: the designers deemed 16 rounds to be sufficient against known types of attack but specified 32 rounds as insurance against future discoveries in cryptanalysis.[src] The official NIST report on AES competition classified Serpent as having a high security margin like MARS and Twofish and in contrast to the adequate security margin of RC6 and Rijndael (currently AES).[src] In final voting, Serpent had the fewest negative votes among the finalists but ranked in second place overall because Rijndael had substantially more positive votes, the deciding factor being that Rijndael allowed for a far more efficient software implementation.[src] The Serpent cipher algorithm is in the public domain and has not been patented.[src] The reference code is public domain software, and the optimized code is licensed under the GPL.[src] There are no restrictions or encumbrances regarding its use.[src] As a result, anyone is free to incorporate Serpent in their software (or in hardware implementations) without paying license fees.[src] define FRAC 0x9e3779b9 // fractional part of the golden ratio define ROTL(A, n) ((A) > 32-n) uint32_t key[8]; // key provided by user uint32_t subkey[33][4]; // roundkeys const uint8_t S[8][16] = {}; // S-boxes /* key schedule: get prekeys */ void get_pre(uint32_t w[4*33], const uint32_t k[8]) { uint32_t x[4*33+8]; for (int i = 0; i > k) & 0x1) > k) & 0x1) > k) & 0x1) > k) & 0x1) > j) & 0x1) The initial permutation works on 128 bits at a time moving bits around.[src] for i in 0 ..[src] 127 swap( bit(i), bit((32 * i) % 127) ) The final permutation works on 128 bits at a time moving bits around.[src] for i in 0 ..[src] 127 swap( bit(i), bit((4 * i) % 127) ) // The input is the result of key mixing and substitution.[src] for (short i = 0; i ==Serpent-0 vs.[src] Serpent-1== The original Serpent, Serpent-0, was presented at the 5th workshop on Fast Software Encryption, but a somewhat tweaked version, Serpent-1, was submitted to the AES competition.[src] The AES submission paper discusses the changes, which include key-scheduling differences.[src] ==Security== The XSL attack, if effective, would weaken Serpent (though not as much as it would weaken Rijndael, which became AES).[src] However, many cryptanalysts believe that once implementation considerations are taken into account the XSL attack would be more expensive than a brute force attack.[src] In 2000, a paper by Kohno et al.[src] presents a meet-in-the-middle attack against 6 of 32 rounds of Serpent and an amplified boomerang attack against 9 of 32 rounds in Serpent.[src] A 2001 attack by Eli Biham, Orr Dunkelman and Nathan Keller presents a linear cryptanalysis attack that breaks 10 of 32 rounds of Serpent-128 with 2 118 known plaintexts and 2 89 time, and 11 rounds of Serpent-192/256 with 2 118 known plaintexts and 2 187 time.[src] A 2009 paper has noticed that the nonlinear order of Serpent S-boxes were not 3 as was claimed by the designers.[src] Specifically, four elements had order 2.[src] A 2011 attack by Hongjun Wu, Huaxiong Wang and Phuong Ha Nguyen, also using linear cryptanalysis, breaks 11 rounds of Serpent-128 with 2 116 known plaintexts, 2 107.5 time and 2 104 memory.[src] The same paper also describes two attacks which break 12 rounds of Serpent-256.[src] The first requires 2 118 known plaintexts, 2 228.8 time and 2 228 memory.[src] The other attack requires 2 116 known plaintexts and 2 121 memory but also requires 2 237.5 time.[src] ==See also== Tiger – hash function by the same authors ==Footnotes== ==Further reading== ==External links== 256 bit ciphers – SERPENT Reference implementation and derived code[src]
43 sentences · 43 cited inline · 0 references stored
References
No reference rows published for this article.
Cite this article
MLA
"Serpent (cipher)." encyclopegia.org, 2026, https://encyclopegia.org/wiki/serpent-cipher. Accessed 25 November 2026.
Chicago
"Serpent (cipher)." encyclopegia.org. Accessed November 25, 2026. https://encyclopegia.org/wiki/serpent-cipher.
APA
encyclopegia.org. (2026). Serpent (cipher). Retrieved November 25, 2026, from https://encyclopegia.org/wiki/serpent-cipher
Accessed November 25, 2026 · CC BY-SA 4.0 · citation page · JSON