Download ProVerif 1.85: Automatic Cryptographic Protocol Verifier, User
Transcript
4.3. FURTHER SECURITY PROPERTIES 43 Example: Decisional Diffie-Hellman assumption The decisional Diffie-Hellman (DDH) assumption states that, given a cyclic group G of prime order q with generator g, (g a , g b , g ab ) is computationally indistinguishable from (g a , g b , g c ), where a, b, c are random elements from Z∗q . A formal counterpart of this property can be expressed as an equivalence using the ProVerif script below (file docs/dh-fs.pv). 1 2 3 4 5 6 7 8 9 10 11 12 13 free d : channel . type G. type exponent . const g : G [ data ] . fun exp (G, exponent ) : G. equation f o r a l l x : exponent , y : exponent ; exp ( exp ( g , x ) , y ) = exp ( exp ( g , y ) , x ) . process new a : exponent ; new b : exponent ; new c : exponent ; out ( d , ( exp ( g , a ) , exp ( g , b ) , choice [ exp ( exp ( g , a ) , b ) , exp ( g , c ) ] ) ) ProVerif succeeds in proving this equivalence. Intuitively, this result shows that our model of the DiffieHellman key agreement is stronger than the Decisional Diffie-Hellman assumption. Observe that the biprocess out(d,(exp(g,a),exp(g,b),choice[exp(exp(g,a),b),exp(g,c )])) is equivalent to out ( choice [ d , d ] , ( choice [ exp ( g , a ) , exp ( g , a ) ] , choice [ exp ( g , b ) , exp ( g , b ) ] , choice [ exp ( exp ( g , a ) , b ) , exp ( g , c ) ] ) ) . That is, choice[M,M] may be abbreviated as M; it follows immediately that the choice operator is only needed to model the terms that are different in the pair of processes. Real-or-random secrecy In the computational model, one generally expresses the secrecy of a value x by saying that x is indistinguishable from a fresh random value. One can express a similar idea in the formal model using observational equivalence. For instance, this notion can be used for proving secrecy of a session key k, as in the following variant of the fixed handshake protocol of Chapter 3 (file docs/ex handshake RoR.pv). 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 free c : channel . l e t c l i e n t A (pkA : pkey , skA : skey , pkB : spkey ) = out ( c , pkA ) ; in ( c , x : b i t s t r i n g ) ; l e t y = adec ( x , skA ) in l e t (=pkA,=pkB , k : key ) = c h e c k s i g n ( y , pkB ) in new random : key ; out ( c , choice [ k , random ] ) . l e t s e r v e r B ( pkB : spkey , skB : s s k e y , pkA : pkey ) = in ( c , pkX : pkey ) ; new k : key ; out ( c , aenc ( s i g n ( ( pkX , pkB , k ) , skB ) , pkX ) ) . process new skA : s k e y ; new skB : s s k e y ; l e t pkA = pk ( skA ) in out ( c , pkA ) ; l e t pkB = spk ( skB ) in out ( c , pkB ) ; ( ( ! c l i e n t A (pkA , skA , pkB ) ) | ( ! s e r v e r B ( pkB , skB , pkA ) ) )