## 4 Identity Management and Access Control Based on Blockchain under Edge Computing for IIoT
### Lightweight Key Exchange Based on Self-Certified Public Key  
Similar to identity-based key system, the scheme in SCKBS does not need a certificate to guarantee the reliability of public key. Moreover, the public key itself has a self-authentication function. Although the scheme of SCKBS also relies on key distribution center (KDC), KDC does not directly generate the private key of network terminals. KDC only produces a part of the private key corresponding to the terminals' identity. The terminals get the actual private key, which effectively solves the key escrow problem. In addition, SCKBS is based on elliptic curve cryptography, which can reduce computation and communication and improve execution efficiency. Therefore, it is particularly suitable for resource-constrained edge networks. The proposed scheme is as follows: \(H_{1}:\{0,1\}^{*}\to Z_{q}\) and \(H_{2}:\{0,1\}^{*}\to\{0,1\}^{\lambda}\) are two Hash functions. For each party \(\hat{A}\), its two long-term private keys are \(a_{1},a_{2}\in Z_{q}\), and the corresponding long-term public key is \(A_{1}=a_{1}P,A_{2}=a_{2}P\). Let \(\hat{A}\) and \(\hat{B}\) be two participants in the agreement and each have two long-term public and private key pairs. (1) \(\hat{A}\hat{A}\) selects the short-term private key \(\widetilde{x}\in\{0,1\}^{\lambda}\), calculates \(x=H_{1}(\widetilde{x},a_{1},a_{2})\) and the transient public key \(X=xP\), destroys \(x\), and sends \(\left(\hat{B},\hat{A},X\right)\) to \(\hat{B}\hat{B}\). (2) After receiving \(\left(\hat{B},\hat{A},X\right)\), \(\hat{B}\hat{B}\) verifies \(X\). \(\hat{B}\) selects the short-term private key \(\overline{y}\in\{0,1\}^{\lambda}\), calculates \(y=H_{1}(\overline{y},b_{1},b_{2})\) and the short-term public key \(Y=yP\), destroys \(y\), and sends \(\left(\hat{A},\hat{B},X,Y\right)\) to \(\hat{A}\). \(\hat{B}\) calculates \(Z_{1}=\left(y+b_{1}\right)(X\cdot A_{1})\), \(Z_{2}=\left(y+b_{2}\right)(X\cdot A_{2})\), \(Z_{3}=yX\), and \(SK=H_{2}\left(Z_{1},Z_{2},Z_{3},X,Y,\hat{A},\hat{B}\right)\). \(\hat{B}\) uses \(SK\) as its session key. (3) After receiving \(\left(\hat{A},\hat{B},X,Y\right)\), \(\hat{A}\) verifies \(Y\). \(\hat{B}\) calculates \(Z_{1}=(x+a_{1})(Y\cdot B_{1})\), \(Z_{2}=(x+a_{2})(Y\cdot B_{2})\), \(Z_{3}=xY\), and \(SK=H_{2}\left(Z_{1},Z_{2},Z_{3},X,Y,\hat{A},\hat{B}\right)\). \(\hat{A}\) uses \(SK\) as its session key. **Theorem 1**. : _If \(H_{1}\) and \(H_{2}\) are random oracles, and ECDH is assumed to be true for group E(Fp), the proposed protocol is eCK model-safe._  
**eCK Model Security. **  
Figure 5: Identity and certificate management based on blockchain. The eCK model is an important tool to analyze protocol. It consists of a set of protocol participants. For the security parameter \(\mathsf{k}\), the advantage \(Adv_{M,\Sigma}^{AKE}(k)\) of the PPT attacker m attack protocol \(\Sigma\) is \(Adv_{M,\Sigma}^{AKE}(k)=\left|Succ_{M,\Sigma}^{AKE}(k)-\frac{1}{2}\right|\), \(Succ_{M,\Sigma}^{AKE}(k)\) is the probability of the bit \(\hat{b}=b\) output by the attacker when making a test query on the fresh oracle. If the advantage \(Adv_{M,\Sigma}^{AKE}(k)\) is negligible for any PPT attacker \(M\), then the protocol \(\Sigma\) is secure. Let \(\lambda\) be the security parameter and \(M\) be the attacker of the protocol. If there is such an \(M\) to win the indistinguishable game with a non-negligible probability, that is, after the Test query, the value of \(b\) is correctly guessed. Let us illustrate how to construct a simulator \(S\) that uses \(M\) to solve the ECDH problem with a non-negligible advantage. \((U,V)\) is the ECDH challenge of \(S\). Among that, \(U,V\in E\big{(}F_{p}\big{)}\), whose task is to compute ECDH == D. **I. ** Forgery attack: At a certain moment, \(M\) calculates \(Z_{1}\),\(Z_{2}\),\(Z_{3}\), and does a query to \(H_{2}\) with pair \(\big{(}Z_{1},Z_{2},Z_{3},X,Y,\hat{A},\hat{B}\big{)}\). **II.