Skip to content
Pseudorandom Function and Permutation

Pseudorandom Function and Permutation

Let Funcn\text{Func}_n be all functions mapping {0,1}n\{0,1\}^n to {0,1}n\{0,1\}^n, and Funcn=2n2n\left| \text{Func}_n \right| = 2^{n \cdot 2^n}.

Then, a random function fFuncnf \in \text{Func}_n is chosen uniformly.

Keyed Functions

Let F:{0,1}×{0,1}{0,1}F: \{0,1\}^* \times \{0,1\}^* \rightarrow \{0,1\}^* be an efficient, deterministic algorithm, and define Fk=F(k,x)F_k = F(k, x), then the first input kk is called the key.

Then, choose a uniform k{0,1}nk \in \{0,1\}^n is equivalent to choosing the function Fk:{0,1}n{0,1}nF_k: \{0,1\}^n \rightarrow \{0,1\}^n, thus, the algorithm FF defines a distribution over functions in Funcn\text{Func}_n.

Therefore, Fk{0,1}nFuncnF_{k \in \{0,1\}^n} \subset \text{Func}_n, and the number of Fk{0,1}nF_{k \in \{0,1\}^n} is at most 2n2^n.

Pseudorandom Functions Definition (PRFs)

The formal definition of pseudorandom functions is:

FF is a pseudorandom function if FkF_k, for uniform key k{0,1}nk \in \{0,1\}^n, is indistinguishable from a uniform function fFuncnf \in \text{Func}_n.

Pseudorandom Permutations (PRPs)

Let fFuncnf \in \text{Func}_n, ff is a permutation if it is a bijection, which means f1f^{-1} exists.

Let PermnFuncn\text{Perm}_n \subset \text{Func}_n be the set of permutations.

Permn=2n×(2n1)×(2n2)××1=(2n)! \left| \text{Perm}_n \right| = 2^n \times (2^n - 1) \times (2^n - 2) \times \dots \times 1 = (2^n)!

Keyed Permutation

Let FF be a length-preserving, keyed function, then FF is a keyed permutation if FkF_k is a permutation for every kk, and F1F^{-1} is efficiently computable.

FF is a strong pseudorandom permutation if FkF_k for uniform key k{0,1}nk \in \{0,1\}^n, is indistinguishable from a uniform permutation fPermnf \subset \text{Perm}_n.

Last updated on