🎉 从330转为WashU帮助手册啦!

CSE442
模块
Cse442t L12

Lecture 12

Continue on pseudo-randomness

{Xn}\{X_n\} and {Yn}\{Y_n\} are distinguishable by μ(n)\mu(n) if \exists distinguisher DD

P[xXn:D(x)=1]P[yYn:D(y)=1]μ(n)|P[x\gets X_n:D(x)=1]-P[y\gets Y_n:D(y)=1]|\geq \mu(n)
  • If μ(n)1p(n)poly(n)\mu(n)\geq \frac{1}{p(n)}\gets poly(n) for infinitely many n, then {Xn}\{X_n\} and {Yn}\{Y_n\} are distinguishable.
  • Otherwise, indistinguishable (diff<ε(n)|diff|<\varepsilon(n))

Property: Closed under efficient procedures.

If MM is any n.u.p.p.t. which can take a ample from tt from Xn,YnX_n,Y_n as input M(Xn)M(X_n)

If {Xn}{Yn}\{X_n\}\approx\{Y_n\}, then so are {M(Xn)}{M(Yn)}\{M(X_n)\}\approx\{M(Y_n)\}

Proof:

If DD distinguishes M(Xn)M(X_n) and M(Yn)M(Y_n) by μ(n)\mu(n) then D(M())D(M(\cdot)) is also a polynomial-time distinguisher of Xn,YnX_n,Y_n.

Hybrid Lemma

Let Xn0,Xn1X^0_n,X^1_n are ensembles indexed from 1,..,m1,..,m

If DD distinguishes Xn0X_n^0 and XnmX_n^m by μ(n)\mu(n), then i,1im\exists i,1\leq i\leq m where Xni1X_{n}^{i-1} and XniX_n^i are distinguished by DD by μ(n)m\frac{\mu(n)}{m}

Proof: (we use triangle inequality.) Let pi=P[tXni:D(t)=1],0imp_i=P[t\gets X_n^i:D(t)=1],0\leq i\leq m. We have p0pmm(n)|p_0-p_m|\geq m(n)

Using telescoping tricks:

p0pm=p0p1+p1p2++pm1pmp0p1+p1p2++pm1pm\begin{aligned} |p_0-p_m|&=|p_0-p_1+p_1-p_2+\dots +p_{m-1}-p_m|\\ &\leq |p_0-p_1|+|p_1-p_2|+\dots+|p_{m-1}-p_m|\\ \end{aligned}

If all pi1pi<μ(n)m,p0pm<μn|p_{i-1}-p_i|<\frac{\mu(n)}{m},|p_0-p_m|<\mu_n contradiction.

In applications, only useful if mq(n)m\leq q(n) polynomial

If X0X_0 and XmX^m are distinguishable by 1p(n)\frac{1}{p(n)}, then 22 inner "hybrids" are distinguishable 1p(n)q(n)=1poly(n)\frac{1}{p(n)q(n)}=\frac{1}{poly(n)}

Example:

For some Brian in Week 1 and Week 50, a distinguisher DD outputs 1 if hair is considered "long".

There is some week i,1i50i,1\leq i\leq 50 pi1pi0.02|p_{i-1}-p_i|\geq 0.02

By prediction lemma, there is a machine that could

P[b{0,1};picXi1+b:A(pic)=b]12+0.022=0.51P[b\to \{0,1\};pic\gets X^{i-1+b}:\mathcal{A}(pic)=b]\geq \frac{1}{2}+\frac{0.02}{2}=0.51

Next bit test (NBT)

We say {Xn}\{X_n\} passes the next bit test if i{0,1,...,l(n)1}\forall i\in\{0,1,...,l(n)-1\} on {0,1}l(n)\{0,1\}^{l(n)} and for all adversaries A:P[tXn:A(t1,t2,...,ti)=ti+1]12+ε(n)\mathcal{A}:P[t\gets X_n:\mathcal{A}(t_1,t_2,...,t_i)=t_{i+1}]\leq \frac{1}{2}+\varepsilon(n) (given first ii bit, the probability of successfully predicts i+1i+1 th bit is almost random 12\frac{1}{2})

Note that for any A\mathcal{A}, and any ii,

P[tUl(n):A(t1,...ti)=ti+1]=12P[t\gets U_{l(n)}:\mathcal{A}(t_1,...t_i)=t_{i+1}]=\frac{1}{2}

If {Xn}{Ul(n)}\{X_n\}\approx\{U_{l(n)}\} (pseudorandom), then XnX_n must pass NBT for all ii.

Otherwise A,i\exists \mathcal{A},i where for infinitely many nn,

P[tXn:A(t1,t2,...,ti)=ti+1]12+ε(n)P[t\gets X_n:\mathcal{A}(t_1,t_2,...,t_i)=t_{i+1}]\leq \frac{1}{2}+\varepsilon(n)

We can build a distinguisher DD from A\mathcal{A}.

The converse if True!

The NBT(Next bit test) is complete.

If {Xn}\{X_n\} on {0,1}l(n)\{0,1\}^{l(n)} passes NBT, then it's pseudorandom.

Idea of proof: full proof is on the text.

Our idea is that we want to create Hnl(n)={Xn}H^{l(n)}_n=\{X_n\} and Hn0={Ul(n)}H^0_n=\{U_{l(n)}\}

We construct "random" bit stream:

Hni={xXn;uUl(n);t=x1x2xiui+1ui+2ul(n)}H_n^i=\{x\gets X_n;u\gets U_{l(n)};t=x_1x_2\dots x_i u_{i+1}u_{i+2}\dots u_{l(n)}\}

If {Xn}\{X_n\} were not pseudorandom, there is a DD

P[xXn:D(x)=1]P[uUl(n):D(u)=1]=μ(n)1p(n)|P[x\gets X_n:D(x)=1]-P[u\gets U_{l(n)}:D(u)=1]|=\mu(n)\geq \frac{1}{p(n)}

By hybrid lemma, there is i,1il(n)i,1\leq i\leq l(n) where:

P[tHi1:D(t)=1]P[tHi:D(t)=1]1p(n)l(n)=1poly(n)|P[t\gets H^{i-1}:D(t)=1]-P[t\gets H^i:D(t)=1]|\geq \frac{1}{p(n)l(n)}=\frac{1}{poly(n)}

l(n)l(n) is the step we need to take transform XX to XnX^n

Let,

Hi=x1xiui+1ul(n)Hi=x1xixi+1ul(n)H^i=x_1\dots x_i u_{i+1}\dots u_{l(n)}\\ H^i=x_1\dots x_i x_{i+1}\dots u_{l(n)}

notice that only two bits are distinguished in the procedure.

D can distinguish xi+1x_{i+1} from a truly random Ui+1U_{i+1}, knowing the first ii bits xixix_i\dots x_i came from xxnx\gets x_n

So DD can predict xi+1x_{i+1} from x1xix_1\dots x_i (contradicting with that XX passes NBT)

EOP

Pseudorandom Generator

Suppose G:{0,1}{0,1}G:\{0,1\}^*\to\{0,1\}^* is a pseudorandom generator if the following is true:

  1. GG is efficiently computable.
  2. G(x)xx|G(x)|\geq |x|\forall x (expansion)
  3. {xUn:G(x)}n\{x\gets U_n:G(x)\}_n is pseudorandom

nn truly random bits \to n2n^2 pseudorandom bits

PRG exists if and only if one-way function exists

The other part of proof will be your homework, damn.

If one-way function exists, then Pseudorandom Generator exists.

Idea of proof:

Let f:{0,1}n{0,1}nf:\{0,1\}^n\to \{0,1\}^n be a strong one-way permutation (bijection).

xUnx\gets U_n

f(x)xf(x)||x

Not all bits of xx would be hard to predict.

Hard-core bit: One bit of information about xx which is hard to determine from f(x)f(x). P[P[ success ]12+ε(n)]\leq \frac{1}{2}+\varepsilon(n)

Depends on f(x)f(x)