A message from our CEO about the future of Stack Overflow and Stack Exchange. Read now.

# Questions tagged [s-boxes]

(or substitution boxes), components in many block ciphers used to substitute parts of the data in a non-linear way. While often fixed by the algorithm (like in DES and AES), sometimes they are key-dependent (like in Blowfish).

189 questions
Filter by
Sorted by
Tagged with
239 views

### How to calculate the non-linearity of an s-box? [duplicate]

I am struggling to understand how to calculate non-linearty of an s-box, could someone show me a detailed example? I found “How to calculate non linearity of AES S-box?” which helped a little, but I ...
340 views

### Rijndael S-boxes: Where do the $\mu$ and $\nu$ polynomial ring elements come from?

I've asked some other questions before about Rijndael's S-boxes, and step by step I'm coming to an understanding; but those steps often guide me to new questions. I did some lines of code to ...
367 views

### Performing differential cryptanalysis for randomly generated S-boxes

As far as I know, performing differential or linear cryptanalysis always requires a knowledge of the S-boxes' content and order. Yet in Bruce Schneier's Applied Cryptography, it is stated that random ...
839 views

### Evaluating Algebraic Complexity of a S-box

While studying the design and the desirable properties of an AES S-box , I came to know that Algebraic Complexity is also an important property of an S-box which is usually considered while evaluating ...
5k views

### How are the AES inverse S-Boxes calculated?

I would like to know, how to calculate the inverse S-box. I followed this link (with affine transformation first, then multiplicative inverse), but the result is wrong. For example, if I use the value ...
945 views

### How are calculated numbers in AES S-box?

I have a problem calculating the 0x02 value of the AES S-Box. I followed the steps descibed in “How are the AES S-Boxes calculated?”, but my answer is not correct. ...
458 views

### Is the DES F-function injective for a given subkey?

Is it possible for two different half-block inputs to the DES F-function, with the same round subkey, to produce the same output? That is, if we feed two different half-block inputs $b_1$ and $b_2$ ...
341 views

### CAST-256 (CAST6) versions or S-Boxes

Are there different versions of CAST-256 - also known as CAST6 - available? Are there different S-Boxes available for CAST-256? If there are different versions or S-Boxes what identifier should I use ...
778 views

767 views

I've recently read a question about the irreducible polynomial behind the subBytes() operation in the Rijndael that has awakened and old curiosity I have: Why $\,m(x)$ was chosen as $\,x^8+x^4+x^3+x+... 1answer 660 views ### Are the MD5 constants an S-Box? I noticed that several hash algorithms, in this case MD5, defines some constants. MD5 defines 64 constant values (the shift count per round) which also gets expand (via sine) to a summand for a ... 2answers 7k views ### Reason why “XOR” is a linear operation, but ordinary “addition” isn’t? I'm new in cryptography and try to read some articles in this field. Many of these articles talk about non-linear S-boxes, and nothing more on what they mean by their non-linearity. I have a simple ... 2answers 972 views ### Two-dimensional S-Box Consider the following simple cipher: $$c_1 = S(m_1 \oplus k_1) \oplus k_2$$ Where$S$is S-box,$m_1$- 16-bit plain text,$k_1$and$k_2$is two parts of 16-bit key. If S-box is standard then this ... 1answer 243 views ### How would using only one s-box affect security of Blowfish? Schneier says: Fewer and smaller S-boxes. It may be possible to reduce the number of S-boxes from four to one. Additionally, it may be possible to overlap entries in a single S-box: entry 0 ... 3answers 2k views ### AES column mixing and S-Box confusion I am trying to understand the AES encryption algorithm. I know that we process 128 bits at a time for a 128 bit key in a 4x4 octet form, but am confused by the following: How does the substitution ... 1answer 967 views ### Serpent cipher : Osvik S-Boxes confusion and test vectors I'm having hard time with the implementation of the S-Boxes by Osvik found in this paper: Speeding up Serpent. At the end of the paper, all the s-boxes are given and then, I just implement them. Here'... 1answer 1k views ### Serpent block cipher : S0 to S7 functions unclear I am presently implementing the serpent block cipher in C++ following the specifications. It's important to mention that I'm implementing the cipher in bitslice mode. You'll need the The full ... 1answer 38k views ### How are the AES S-Boxes calculated? I'm trying to understand how the AES S-Boxes are calculated. I understand how the multiplicative inverse is calculated over$GF(2^8)$, but I'm confused by the description of the affine transformation. ... 1answer 2k views ### Where is the S-Box generated in Rijandel/AES? It's rather kind of lame questions, and I can't find good and clear explanation: In which step of Rijandel is S-box generated? Is the S-box reused in every round of cipher or is generated in every ... 1answer 34k views ### How does DES decryption work? Is it the same as encryption or the reverse? [duplicate] If DES decryption is the same as encryption done in reverse order, then how can the reversed S-Box convert 4 bits into 6 bits? 2answers 724 views ### How do I choose the best 3*3 s-boxes? I've read about 20 papers about the criteria for choosing best$n \times n$s-boxes. Now, I've got two problems: How to generate$2^{24}$s-boxes, and how to test them considering the criteria. ... 1answer 6k views ### How can an S-Box be reversed? So, as an exercise to greater understand some things about cryptography, I decided to try and implement GOST 28147-89, which uses eight 4x4 S-Boxes. I can grasp the concept of putting 4 bits through ... 1answer 595 views ### S-box with differential uniformity = 2 I read that we do not know if there exists an 8x8 sbox with differential uniformity = 2. I suppose we cannot compute every possible sbox because there are$64!$possible s-boxes. Am I right? 1answer 4k views ### S-box design criteria and random sboxes What are the disadvantages of using random s-boxes? In AES, the s-boxes had to obey certain mathematical rules, which? And why? What security does using hidden s-boxes (GOST) or generating them from ... 2answers 9k views ### Why do block ciphers need a non-linear component (like an S-box)? Why is there a requirement of "Non-Linear functions" as a component of many popular block ciphers (e.g. the S-box in DES or 3DES)? How does it make the cipher more secure? The only intuition I have ... 1answer 466 views ### S-box Cryptanalytic Resistance In DES, different S-boxes were tested for cryptanalytic resistance and the most secure one was chosen for the algorithm itself. How do different S-boxes offer different levels of security against ... 5answers 7k views ### Desirable S-box properties What desirable properties should an S-box have? My current standard selection process is to just pick them at random and verify that they fit the following criteria: The probability that any random ... 3answers 3k views ### Security of simple xor and s-box cipher? What weaknesses (or strengths) do block ciphers based on only key xor and s-box have when operating in CBC mode? A cipher's internal primitive might be a simple as this:$C = S[M \oplus k]$, where$...
The Rijndael S-Box design generates a permutation cycle of type $2+27+59+81+87$. What effect would replacing that permutation with a cycle of type $256$ have on the security of AES?