Einwegfunktionen
Ziel:CPA-sichere Verschlüsselung aus Trapdoor-Einwegpermutation Später:CCA-sichere Verschlüsselung aus Trapdoor-Einwegperm.
SpielInvertierenInvertA,f(n)
Seif :{0,1}∗→ {0,1}∗ effizient berechenbar,Aein Invertierer fürf.
1 Wählex ∈R {0,1}n. Berechney ←f(x).
2 x0 ← A(1n,y)
3 InvertA,f(n) =
(1 fallsf(x0) =y
0 sonst .
DefinitionEinwegfunktion
Eine Funktionf :{0,1}∗ → {0,1}∗heißtEinwegfunktion, falls
1 Es existiert ein deterministischer pt AlgBmitf(x)← B(x).
2 Für alle ppt AlgorithmenAgiltWs[InvertA,f(n) =1]≤negl(n).
Spiel Invertieren
InvertA,f(n) W¨ahle: x∈R{0,1}n
Berechne: y←f(x) (1n, y)
Ausgabe:
(1 fallsf(x0) =y 0 sonst
A
Berechne:
x0 ∈ {0,1}n x0
Existenz von Einwegfunktionen
Problem:Existenz von Einwegfunktionen ist ein offenes Problem.
Satz(Levin)
Wenn Einwegfunktionen existieren, dann kann man auch explizit eine angeben.
Beweis (Idee). Konstruktion vonfLevin mit Eingabex.
1 Interpretierex =M||z, mit|M|=log|z|.
2 FühreM auf Eingabez aus.
3 DefinierefLevin(x)=
M(z): M terminiert nach|z|3Schritten
⊥ : sonst Mann kann zeigen:
Falls Einwegfunktionen existieren, dann gilt für alle pptA:
Ws[InvertA,fLevin(n) =1]≤1−1/q(n), für ein Polynomq.
Durch "Hardness amplification" kann ausfLevin eine EinwegfunktionfLevin0 konstruiert werden.
Die Faktorisierungsannahme
Konstruktion eine Einwegfunktion unter Komplexitätsannahme (z.B. Faktorisierung)
Verwenden dazu(N,p,q)←GenModulus(1n)von RSA.
SpielFaktorisierungsspielFactorA,GenModulus(n)
1 (N,p,q)←GenModulus(1n)
2 (p0,q0)← A(N)mitp0,q0 >1.
3 FactorA,GenModulus(n) =
(1 fallsp0q0 =N
0 sonst .
Spiel Faktorisieren
FactorA,GenModulus(n)
(N, p, q)←GenModulus(1n) (1n, N)
Ausgabe:
(1 fallsp0q0=N 0 sonst
A
Berechne:
p0, q0>1 (p0, q0)
DefinitionFaktorisierungsannahme
Faktorisieren ist hart bezüglichGenModulusfalls für alle ppt AlgorithmenAgiltWs[FactorA,GenModulus(n) =1]≤negl(n).
Faktorisierungsannahme:Faktorisieren ist hart bezüglichGenModulus.
Konstruktion aus Faktorisierungsannahme
Seip(n)ein Polynom, so dassGenModulus(1n)höchstensp(n) Zufallsbits verwendet.
OBdA seip(n) :N→Nmonoton wachsend.
Algorithmus FACTOR-ONEWAYfFO
Eingabe:x ∈ {0,1}∗
1 Berechnenmitp(n)≤ |x|<p(n+1).
2 (N,p,q) :=GenModulus(1n,x), wobeiGenModulusdie Eingabex als internen Zufallsstring verwendet.
Ausgabe:N Bemerkung:
GenModulus(1n,x)ist deterministisch. (Derandomisierung)
Existenz von Einwegfunktionen
SatzEinweg-Eigenschaft vonfFO
Unter der Faktorisierungsannahme istfFOeine Einwegfunktion.
Beweis:
SeiAein Invertierer fürfFOmit Erfolgsws(n).
Konstruieren mitAFaktorisiererA0im SpielFactorA0,GenModulus(n).
Algorithmus FaktorisiererA0 EINGABE: 1n, N
1 x0 ← A(1n,N).
2 (N0,p0,q0)←GenModulus(1n,x0).
AUSGABE:p0,q0
Unter der Faktorisierungsannahme gilt
negl(n)≥Ws[FactorA0,GenModulus(n) =1] =Ws[InvertA,fFO(n) =1] =(n).
Faktorisieren mit Invertierer für f
FOFactorA0,GenM odulus
(N, p, q)←GenModu−
lus(1n)
(1n, N)
Ausgabe:
=
(1 fallsN =p0q0 0 sonst
FaktorisiererA0
(1n, N)
(N0, p0, q0) :=
GenModulus(1n, x0) p0, q0
A
x0
Trapdoor-Funktionsfamilie
DefinitionFunktionsfamilie
EineFunktionsfamilieΠf = (Gen,Samp,f)besteht aus 3 ppt Alg:
1 I←Gen(1n), wobeiIeine UrbildmengeDfürf definiert.
2 x ←Samp(I), wobeix ∈R D.
3 y :=fI(x)undfI :D →D ist bijektiv.
DefinitionTrapdoor-Funktionsfamilie
Trapdoor-FunktionsfamilieΠf = (Gen,Samp,f,Inv)besteht aus
1 (I,td)←Gen(1n)mittd als Trapdoor-Information.
2 x ←Samp(I)wie zuvor.
3 y :=fI(x)wie zuvor.
4 x ←Invtd(y)mitInvtd(fI(x)) =x für allex ∈D.
Πf is eine(Trapdoor-)Permutationsfamilie, fallsR=DundfI :D→D bijektiv ist.
SpielInvertieren einer FunktionInvertA,Πf(n) SeiAein Invertierer für die FamilieΠf.
1 I←Gen(1n),x ←Samp(I)undy :=fI(x).
2 x0 ← A(I,y).
3 InvertA,Π(n) =
(1 fallsfI(x0) =y
0 sonst .
InvertA,Πf(n)
I←Gen(1n) x←Samp(I)
y←fI(x) (1n, I, y)
Ausgabe:
(1 fallsf(x0) =y 0 sonst
A
Berechnex0. x0
Konstruktion einer Trapdoor-Einwegfunktion
DefinitionEinweg-Funktion
Eine (Trapdoor-)Funktionsfamilie heißt(Td-)Einwegfunktionfalls für alle ppt AlgorithmenAgiltWs[InvertA,Πf(n) =1]≤negl(n).
Bsp:Trapdoor-Einwegpermutation unter RSA-Annahme Gen(1n):
(N,e,d)←GenRSA(1n), AusgabeI= (N,e)undtd = (N,d).
Samp(I):
Wählex ∈R ZN. fI(x):
Berechney :=xemodN.
Invtd(y):
Berechnex :=ydmodN.
Hardcore-Prädikat
Ziel:Destilliere Komplexität des Invertierens auf ein Bit.
DefinitionHardcore-Prädikat
SeiΠf eine Einwegfunktion. Seihc ein deterministischer pt Alg mit Ausgabe eines Bitshc(x)bei Eingabex ∈D.hc heißt
Hardcore-Prädikatfürf falls für alle ppt AlgorithmenAgilt:
Ws[A(1n,I,f(x)) =hc(x)]]≤ 12+negl(n).
Intuition:Bildf(x)hilft nicht beim Berechnen vonhc(x).
Spiel zum Berechnen des Hardcore-Prädikats
CompHCA,Πf(n)
I←Gen(1n) x←Samp(I)
y←fI(x) (1n, I, y)
Ausgabe:
(1 fallshc(x) =b0 0 sonst
A
Berechneb0. b0
Fallshcein Hardcoreprädikat ist, so gilt für alle pptA
Ws[CompHCA,Πf(n) =1]=Ws[A(1n,I,f(x)) =hc(x)]]≤ 12+negl(n).
Hardcore-Prädikate
hc(x) :=lsb(x)(least significant bit) ist ein Hardcoreprädikat für die RSA EinwegpermutationΠRSA(unter der RSA Annahme).
Es kann kein festes Hardcoreprädikathcfür alle Einwegfunktionen geben.
Warum? SeiΠf Einwegfunktion mit Hardcoreprädikathc. Dann ist Πgmitg(x) :=f(x)||hc(x)auch eine Einwegfunktion, aberhckein Hardcoreprädikat vonΠg.
Aber: Man kann jede EinwegfunktionΠf zu einer Einwegfunktion Πgmit einem festen Hardcoreprädikat verändern.
Goldreich-Levin Hardcore-Prädikat
Satzvon Goldreich-Levin
SeiΠf eine Einwegpermutation. Dann existiert eine EinwegpermutationΠgmit Hardcoreprädikathc.
Konstruktion:(ohne Beweis)
Seif eine Einwegpermutation mit Definitionsbereich{0,1}n. Seix =x1. . .xn∈ {0,1}n. Konstruiere
g(x,r) := (f(x),r)mitr ∈R{0,1}n. Offenbar istgebenfalls eine Einwegpermutation.
Wir konstruieren ein Hardcore-Prädikathc fürgmittels hc(x,r) =hx,ri=Pn
i=1xiri mod2.
Beweis der Hardcore-Eigenschaft ist nicht-trivial.
Verschlüsselung aus Trapdoor-Einwegpermutation
Algorithmus Πcpa
SeiΠf eine Td-Einwegpermutation mit Hardcore-Prädikathc.
1 Gen:(I,td)←Gen(1n). Ausgabepk =Iundsk =td.
2 Enc:Fürm∈ {0,1}setzex ←Sample(I)und berechne c ←(f(x),hc(x)⊕m).
3 Dec:Für Chiffretextc= (c1,c2)berechnex :=Invtd(c1)und m:=c2⊕hc(x).
Intuition:
hc(x)ist “pseudozufällig” gegebenf(x).
D.h.hc(x)⊕mist ununterscheidbar von 1-Bit One-Time Pad.
Bsp: Verschlüsselung mit RSA-Td-Einwegpermutation
Algorithmus Πrsacpa
SeiΠrsadie RSA Td-Einwegpermutation mit Hardcore-Prädikathc.
1 Gen:(N,e,d)←GenRSA(1n). Ausgabepk = (N,e)und sk = (N,d).
2 Enc:Fürm∈ {0,1}wähler ∈RZ∗N und berechne c ←(remodN,hc(r)⊕m).
3 Dec:Für Chiffretextc= (c1,c2)berechner :=c1d modN und m←c2⊕hc(r).