Patent ID: 8738914

Claim:
A method for key exchange, comprising: selecting, by a parameter sender A, a random number RA and computes X; performing, by the parameter sender A, a modulo operation on the X to obtain X′, and then sends the X′ to a parameter sender B; checking, by the parameter sender B, whether the X′ is 0; selecting, by the parameter sender B, a random number R B and computes Y and S 1 ′; if the X′ is not 0; performing, by the parameter sender B, a modulo operation on the Y to obtain Y′, and then sending the Y′ and the S 1 ′ to the parameter sender A; checking, by the parameter sender A, whether the Y′ is 0; if the Y′ is not 0; checking, by the parameter sender A, whether the Y′ is valid; if the Y′ is valid; computing, by the parameter sender A, the shared key K′ and S 2 ′, and sending the S 2 ′ to the parameter sender B; checking, by the parameter sender B, whether the S 2 ′ is valid; computing, by the parameter sender B, the shared key K′; wherein the method is based on the password-based key exchange authentication protocol; X=H 1 ( A A |B B |PW )·( g R A mod p ); X′=X mod p=[H 1 ( A A |B B |PW )· g R A ] mod p; Y=H 2 ( A A |B B |PW )·( g R B mod p ); Y′=Y mod p=[H 2 ( A A |B B |PW )· g R B ] mod p ; S 1 ′ = H 3 ( A A ⁢  B B  ⁢ PW ⁢  X ′ H 1 ⁡ ( A A ⁢  B B  ⁢ PW ) ⁢ mod ⁢ ⁢ p  ⁢ g R B ⁢ mod ⁢ ⁢ p  ⁢ { [ X ′ H 1 ⁡ ( A A ⁢  B B  ⁢ PW ) ] R B ⁢ mod ⁢ ⁢ p } ) = H 3 ( A A ⁢  B B  ⁢ PW  ⁢ g R A ⁢ mod ⁢ ⁢ p ⁢  g R B ⁢ mod ⁢ ⁢ p  ⁢ { [ g R A ] R B ⁢ mod ⁢ ⁢ p } ) ⁢ ⁢ K ′ = H 5 ( A A ⁢  B B  ⁢ PW ⁢  g R A ⁢ mod ⁢ ⁢ p  ⁢ Y ′ H 2 ⁡ ( A A ⁢  B B  ⁢ PW ) ⁢ mod ⁢ ⁢ p  ⁢ { [ Y ′ H 2 ⁡ ( A A ⁢  B B  ⁢ PW ) ] R A ⁢ mod ⁢ ⁢ p } ) = H 5 ( A A ⁢  B B  ⁢ PW ⁢  g R A ⁢ mod ⁢ ⁢ p  ⁢ g R B ⁢ mod ⁢ ⁢ p  ⁢ { [ g R B ] R A ⁢ mod ⁢ ⁢ p } ) ⁢ ⁢ S 2 ′ = H 4 ( A A ⁢  B B  ⁢ PW  ⁢ g R A ⁢ mod ⁢ ⁢ p ⁢  Y ′ H 21 ⁡ ( A A ⁢  B B  ⁢ PW ) ⁢ mod ⁢ ⁢ p  ⁢ { [ Y ′ H 2 ⁡ ( A A ⁢  B B  ⁢ PW ) ] R A ⁢ mod ⁢ ⁢ p } ) = H 4 ( A A ⁢  B B  ⁢ PW  ⁢ g R A ⁢ mod ⁢ ⁢ p ⁢  g R B ⁢ mod ⁢ ⁢ p  ⁢ { [ g R B ] R A ⁢ mod ⁢ ⁢ p } ) ; A A and B A are parameters belonging to the parameter sender and the parameter receiver respectively and are known to the parameter sender and the parameter receiver; PW is a secret password shared by the parameter sender and the parameter receiver; R A is private key of the parameter sender; p is a prime number; g is a positive integer; p and g are parameter of Diffie-Hellman; | is a concatenation symbol; mod is the modulo operator; H 1 (*) indicates the hash function.