# EAIA: An Efficient and Anonymous Identity-Authentication Scheme in 5G-V2V
## 5 Proposed Scheme EIA
### Mutual Authentication  
After completing the registration process, mutual authentication between OBUs is required to initiate the establishment of a session key with the nearest proximal OBU. The procedure assumes that \(OBU_{j}\) sends an authentication request to \(OBU_{i}\) and wishes to establish a session key. This procedure is delineated in the following steps and is represented in Figure 3.  
Step 1: If \(OBU_{j}\) requests authentication with \(OBU_{i}\), \(OBU_{j}\) sends its own ID ID, public key \((X_{j}+Y_{j})\), and an authentication request to \(OBU_{i}\). Once \(OBU_{i}\) receives the request from \(OBU_{j}\), it generates random values of \(a,b\in Z_{q}^{*}\) and calculates \(A=aP\), \(B=bP\), \(M=b(X_{j}+Y_{j})\), and \(N=h_{2}(M)\bigoplus(ID_{i}||A)\). This means that \(OBU_{i}\) encrypts its identity using \(OBU_{i}\)'s public key, so only \(OBU_{i}\) can extract \(OBU_{i}\)'s identity. Then, \(OBU_{i}\) calculates \(\sigma=b^{-1}(h_{1}(ID_{i}||A||T_{a}+y_{i})\) as its signature, where Ta represents the current timestamp. Then, \(OBU_{i}\) sends \(\{B,N,\sigma,T_{a}\}\) to \(OBU_{j}\).  
Step 2: After receiving the message \(\{B,N,\sigma,T_{a}\}\) from \(OBU_{i}\), if Ta is not fresh, \(OBU_{j}\) aborts this session. Otherwise, \(OBU_{j}\) computes \(M^{\prime}=(x_{j}+y_{j})B\) and derives \(ID^{\prime}_{i}||A^{\prime}=h_{2}(M^{\prime})\bigoplus N\). Since we can obtain \(M=M^{\prime}\) from (1), from \(N=h_{2}(M)\bigoplus(ID_{i}||A)\) and \(ID^{\prime}_{i}||A^{\prime}=h_{2}(M^{\prime})\bigoplus N\), we can obtain \(ID_{i}||A=ID^{\prime}_{i}||A^{\prime}\). In this way, it is guaranteed that what \(OBU_{i}\) sends to \(OBU_{j}\) can be received by \(OBU_{j}\). Complete identity authentication for \(OBU_{j}\):  
\[\begin{split} M^{\prime}&=(x_{j}+y_{j})B\\ &=b(x_{j}+y_{j})P\\ &=b(X_{j}+Y_{j})\\ &=M\end{split} \tag{1}\]  
Figure 3: Mutual authentication.  
Then, \(OBU_{j}\) verifies the validity of \(OBU_{i}\) by verifying the signature. \(OBU_{j}\) checks whether \(\sigma B=h_{1}(ID^{\prime}_{i}||A^{\prime}||T_{a})P+Y_{i}\) holds. If it is held, the identity authentication is achieved. The correctness of identity authentication can proved by (2). By doing this, it is guaranteed that the sender is \(OBU_{i}\). Complete identity authentication for \(OBU_{i}\):  
\[\begin{split}\sigma B&=(b^{-1}(h_{1}(ID_{i}||A||T _{a}+y_{i}))B\\ &=b(b^{-1}(h_{1}(ID_{i}||A||T_{a})+y_{i}))P\\ &=(h_{1}(ID_{i}||A||T_{a})P+y_{i})P\\ &=h_{1}(ID_{i}||A||T_{a})P+Y_{i}\end{split} \tag{2}\]  
If the \(OBU_{i}\) verification is successful, it implies that the identity authentication of both parties is successful. Then, the session key negotiation begins. \(OBU_{j}\) randomly selects \(D=dP\), \(d\in Z_{q}^{*}\) and calculates \(k=h_{1}(ID^{\prime}_{i}||ID_{j}||A^{\prime}||D||T_{b})\), \(SK_{j-i}=h_{3}(ID^{\prime}_{i}||ID_{j}||d(KA^{\prime}+X_{i}))\), and \(\eta=h_{4}(ID^{\prime}_{i}||ID^{\prime}_{j}||SK_{j-i}||T_{b})\). Then, \(OBU_{j}\) sends \(\{D,\eta,T_{b}\}\) to \(OBU_{i}\).  
Step 3: After receiving the response of \(OBU_{i}\), if \(T_{b}\) is not fresh, \(OBU_{i}\) adopts this session. Otherwise, \(OBU_{i}\) computes \(k=h_{1}(ID_{i}||ID_{j}||A||D||T_{b})\) and \(SK_{i-j}=h_{3}(ID_{i}||ID_{j}||D(ka+x_{i}))\). Finally, it verifies whether \(\eta=h_{4}(ID_{i}||ID_{j}||SK_{i-j}||T_{b})\) is successful. If the equation holds, mutual authentication is completed with the session key successfully negotiated. Therefore, we have \(SK_{i-j}=SK_{j-i}\) because the following Equation (3) holds:  
\[\begin{split} SK_{j-i}&=h_{3}(ID^{\prime}_{i}||ID_{ j}||d(KA+X_{i}))\\ &=h_{3}(ID^{\prime}_{i}||ID_{j}||d(kaP+x_{i}P))\\ &=h_{3}(ID_{i}||ID_{j}||dP(ka+x_{i}))\\ &=h_{3}(ID_{i}||ID_{j}||D(ka+x_{i}))\\ &=SK_{i-j}\end{split} \tag{3}\]