Pseudorandom Functions

Research Depth 71 in the knowledge graph I know this Set as goal
prf ggm-construction keyed-function indistinguishability

Core Idea

A pseudorandom function (PRF) family {F_k} maps inputs to outputs such that F_k (for a random key k) is computationally indistinguishable from a truly random function, even to an adversary with adaptive oracle access. PRFs are the theoretical model for block ciphers and the core building block for MACs, CPA-secure encryption, and key derivation. The GGM construction proves that PRGs imply PRFs, completing the chain: OWFs → PRGs → PRFs. A pseudorandom permutation (PRP) is a PRF that is also a bijection — the formal model for block ciphers like AES. The PRP/PRF switching lemma shows PRPs and PRFs are interchangeable for most applications when the domain is large.

Explainer

A pseudorandom function (PRF) family is a collection of keyed functions {F_k} such that when k is chosen randomly, the function F_k is computationally indistinguishable from a truly random function — even to an adversary who can adaptively choose inputs and observe outputs. This is a stronger guarantee than PRGs: the adversary has oracle access, meaning they can query F_k on any input of their choosing and see the corresponding output, yet they still cannot tell F_k apart from a genuinely random input-output mapping.

The formal definition captures the ideal behavior of a block cipher. AES with a random key should behave like a random permutation (a special case of a random function that is also a bijection). Every output should appear random given all previously observed input-output pairs, and no pattern in the outputs should reveal the key or predict future outputs. The PRP/PRF switching lemma shows that for large domains (like AES's 128-bit block space), random permutations and random functions are indistinguishable until the adversary has made close to 2^{n/2} queries, making the distinction irrelevant in practice.

The GGM construction (Goldreich, Goldwasser, Micali) builds a PRF from any PRG with expansion factor 2. Think of it as a binary tree: the root holds the key k. Applying the PRG to k produces two values (left and right children). Applying the PRG to each child produces four grandchildren, and so on. To evaluate F_k on an n-bit input x, walk from the root to a leaf, going left when the next input bit is 0 and right when it is 1. The leaf value is the output. The security proof uses a hybrid argument: replace the PRG output at each level with truly random values, one level at a time. Each replacement is undetectable by PRG security, and after n levels all leaves are independent random values — a truly random function. This construction, combined with the HILL theorem (OWFs → PRGs), proves that OWFs suffice for PRFs, completing the foundational chain of cryptographic primitives.

PRFs are the workhorse building block of modern cryptography. CPA-secure encryption: to encrypt message m, pick random r and output (r, F_k(r) XOR m) — this is essentially CTR mode, secure because F_k(r) is pseudorandom. MACs: F_k(m) is a secure MAC for fixed-length messages because forging a tag on a new message requires predicting a PRF output on an unqueried input. Key derivation: F_k(context) derives application-specific keys that are pseudorandom even if the adversary knows other derived keys. The universality of PRFs means that understanding this single primitive — a keyed function indistinguishable from random — unlocks the construction of most symmetric cryptographic tools.

Practice Questions 5 questions

Prerequisite Chain

Counting to 10Counting to 20Understanding ZeroThe Number ZeroCounting to FiveOne-to-One CorrespondenceCombining Small Groups Within 5Addition Within 10Addition Within 20Two-Digit Addition Without RegroupingTwo-Digit Addition with RegroupingAddition Within 100Repeated Addition as MultiplicationMultiplication Facts Within 100Division as Equal SharingDivision as Grouping (Measurement Division)Division: Grouping (Repeated Subtraction) ModelDivision: Fair Sharing ModelDivision as Equal SharingDivision as GroupingBasic Division FactsDivision Facts Within 100Two-Digit by One-Digit DivisionDivision with RemaindersRemainders and Quotients in DivisionDivision Word ProblemsIntroduction to Long DivisionFactors and MultiplesPrime and Composite NumbersEquivalent FractionsRelating Fractions and DecimalsDecimal Place ValueReading and Writing DecimalsComparing and Ordering DecimalsAdding and Subtracting DecimalsMultiplying DecimalsDividing DecimalsDividing FractionsMixed Number ArithmeticOrder of OperationsInteger Order of OperationsVariable ExpressionsCombining Like TermsOne-Step EquationsTwo-Step EquationsSolving Multi-Step EquationsEquations with Variables on Both SidesLiteral EquationsSlope-Intercept FormPoint-Slope FormWriting Linear EquationsParallel and Perpendicular Line SlopesGraphing Linear EquationsPiecewise FunctionsStep FunctionsComposition of FunctionsInverse FunctionsRadical Functions and GraphsRational ExponentsExponential Functions and GraphsLogarithms IntroductionTime and Space ComplexityTime Complexity Classes: P and EXPTIMENondeterministic Time Complexity and NPThe P vs. NP ProblemComplexity Class P: Polynomial TimeHash Functions and Collision ResistanceThe RSA CryptosystemComputational Hardness AssumptionsOne-Way FunctionsPseudorandom GeneratorsPseudorandom Functions

Longest path: 72 steps · 408 total prerequisite topics

Prerequisites (2)

Leads To (0)

No topics depend on this one yet.