Next Article in Journal
Research on Deep-Hole Cutting Blasting Efficiency in Blind Shafting with High In-Situ Stress Environment Using the Method of SPH
Next Article in Special Issue
FORT: Right-Proving and Attribute-Blinding Self-Sovereign Authentication
Previous Article in Journal
Review of the Latest Progress in Controllability of Stochastic Linear Systems and Stochastic GE-Evolution Operator
Previous Article in Special Issue
A Novel Auction Blockchain System with Price Recommendation and Trusted Execution Environment
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

BCmECC: A Lightweight Blockchain-Based Authentication and Key Agreement Protocol for Internet of Things

1
Department of Computer Science and Mathematics, Faculty of Economic Studies, University of Finance and Administration, 101 00 Prague, Czech Republic
2
Future Technology Research Center, National Yunlin University of Science and Technology, Douliou 64002, Taiwan
3
Department of Information Systems, College of Economics and Political Science, Sultan Qaboos University, Muscat P.C.123, Oman
4
Electrical Engineering Department, Shahid Rajaee Teacher Training University, Tehran 16788-15811, Iran
5
Faculty of Computer Engineering, Shahid Rajaee Teacher Training University, Tehran 16788-15811, Iran
6
Department of Information Technology, University of Human Development, Sulaymaniyah 0778-6, Iraq
7
Pattern Recognition and Machine Learning Lab, Gachon University, 1342 Seongnamdaero, Sujeonggu, Seongnam 13120, Korea
*
Author to whom correspondence should be addressed.
Mathematics 2021, 9(24), 3241; https://doi.org/10.3390/math9243241
Submission received: 10 November 2021 / Revised: 30 November 2021 / Accepted: 9 December 2021 / Published: 14 December 2021
(This article belongs to the Special Issue Advances in Blockchain Technology)

Abstract

:
In this paper, targeting efficient authentication and key agreement in an IoT environment, we propose an Elliptic Curve Cryptography-(ECC) based lightweight authentication protocol called BCmECC which relies on a public blockchain to validate the users’ public key to provide desired security. We evaluate the security of the proposed protocol heuristically and validate it formally, which demonstratse the high level of the security. For the formal verification we used the widely accepted formal methods, i.e., BAN logic and the Scyther tool. In this paper we also analyse the security of recently proposed blockchain-based authentication protocols and show that this protocol does not provide the desired security against known session-specific temporary information attacks in which the adversary has access to the session’s ephemeral values and aims to retrieve the shared session key. In addition, the protocol lacks forward secrecy, in which an adversary with access to the server’s long-term secret key can retrieve the previous session keys, assuming that the adversary has already eavesdropped the transferred messages over a public channel in the target session. The proposed attacks are very efficient and their success probability is ‘1’, while the time complexity of each attack could be negligible. Besides, we show that BCmECC is secure against such attacks.

1. Introduction

The Internet of Things (IoT) will have an impact on every element of human life very soon. The existing networks and devices such as cellphones, laptop computers, cloud servers, and so on which have surrounded people in the twenty-first century could just be a part of IoT. There are many devices with the capability to connect this network already, including all smart home appliances. On the other hand, organized criminal gangs exist wherever there is a profit to be made from counterfeiting or pirate operations, usually by circumventing security barriers. Despite ongoing efforts to monitor this risk, the share of trade in counterfeit and pirated goods is steadily increasing, and fake or fraudulent products can be found in an increasing number of industries, including pharmaceuticals, food and beverage, and medical equipment, posing serious health and safety risks [1,2,3,4,5]. To counteract the increased threat of counterfeit products and drugs, government authorities such as the US Food and Drug Adminstration(FDA) and organizations (such as pharmaceutical suppliers) are looking into enforcement options, one of which is IoT solutions, which may assist with maintaining a secure supply chain, according to [6].
Although IoT provides many advantages, it also raises many concerns including unauthorized access and control of those devices for adversarial purposes. To address this concern, authentication and access control protocols could be an off-the-shelf solution. However, IoT is a heterogeneous network in which objects with varying capabilities and resources should connect to share information. Hence, the available off-the-shelf solution, authentication protocols, which are used in SSL, for instance, may not be appropriate for this network. As a result, throughout the previous decade, several customized protocols have been designed, analyzed, and broken [1,7,8,9,10,11].
Due to the limited resources of many items in an IoT network, they should rely on external resources for calculations and the storing of sensitive data, such as a trusted authority (TA). Apart from security concerns, such a centralized architecture of traditional protocols could be a bottleneck in the mass IoT network, causing service providers to be unable to adequately respond to system requirements like authentication, authorization, and access management as the number of devices and users grows. To address this concern, decentralized solutions could be a proper solution. Among different approaches, blockchain-based approaches could provide public trust in the network’s security. More precisely, the blockchain may be used to securely store information such as certificates or system parameters which can subsequently be accessed by IoT devices or servers to aid with authentication. A smart contract can also be utilized to establish the link between important data and to conduct revocation when necessary. As a result, the blockchain network enables verifiable, immutable, and undeniable data storage in the form of so-called transactions that comprise a blockchain [12]. Hence, several security and privacy solutions for IoT networks have been presented in this framework, e.g., [13,14,15,16,17,18,19,20,21,22]. An interesting study on the fusion of blockchain and the Internet of Things ( BIoT) has been provided in [21], where the authors identified nine categories in the intellectual core of BIoT, including data privacy and security for BIoT systems, system security theories for BIoT, and applied security strategies for using blockchain with the IoT. Another study, in which a unification of BIoT is provided, has been conducted by Bhushan et al.  [22], where they introduced requirements, a working model, challenges, and future directions of BIoT. While those studies are more concentrated on identifying the challenges, some other studieshave introduced concrete solutions in the field of BIoT. Among them, to accomplish an effective authentication procedure, recently Yang et al. [19] suggested a novel blockchain-based authentication system that combines the blockchain approach with the modular square root algorithm. The suggested protocol has some intriguing characteristics and is backed up by provable security, assuming that the adversary only has access to the messages sent via the public channel. On the other hand, any security protocol should be extensively analysed by the third parties prior to relaying the security of a real application on it [23]. In addition, the security of Yang et al.’s protocol in the face of a more powerful attacker, who may compromise long-term secret parameters or impact primitives’ functionality, such as random generators, is currently unexplained. It motivated us to shed light on those parts of the protocol in order to dig deeper into its security.

1.1. Our Contribution

The paper’s contribution is divided into two parts, as follows:
  • We assess the security of Yang et al.’s recently proposed blockchain-based protocol and show that it is vulnerable to a known session-specific temporary information attack and does not provide forward secrecy.
  • Given the merits of Yang et al.’s scheme, we go one step further and propose a new ECC-based scheme in this platform. The proposed protocol not only improves security but also lowers communication costs and requires fewer primitives, making it a better fit for constrained environments.

1.2. Paper Organization

The rest of the paper is organized as follows: in Section 2, we represent the required preliminaries, including the notations and also some required backgrounds. Next, in Section 3, we review Yang et al.’s scheme as a recent blockchain-based authentication protocol for IoT. In this section, we demonstrate this scheme’s limitations also. To overcome the presented weaknesses and also provide a lightweight authentication protocol for IoT systems, we propose BCmECC in Section 4. The security and efficiency merits of BCmECC are discussed in Section 5 and Section 6 respectively. Finally, the paper is concluded in Section 7.

2. Preliminaries

2.1. Notation

We use the list of notations represented in Table 1 in this paper.

2.2. Blockchain

In 2008, Satoshi Nakamoto proposed Bitcoin as a blockchain-based decentralized digital currency [24]. As a result, blockchain drew a lot of attention and grew in popularity. As seen in Figure 1, a blockchain is made up of blocks that are linked together to form a chain. Each block contains the block number, the hash of the previous block, a nonce, and transaction data. Each block will include the hash of the previous block, which will be used to construct the ledger. Every network node has its own ledger. Consensus mechanisms are at the heart of the blockchain, used to verify transactions and update the whole ledger. When a new transaction is uploaded to the ledger, all nodes in the network double-check the data’s correctness before adding it to their ledger. Each user must register a pair of public and private keys in order to join the network. This is performed by utilizing a transaction. The keys of each user are kept in his or her wallet. The blocks had been mined previously. Miners are network nodes that are responsible for creating and validating blockchain blocks [20]. It is both costly and difficult to change an authorized block in the ledger. Blockchain is divided into two types: public and private. In a public blockchain, anybody may participate in the block generation and consensus process, while only pre-approved nodes can do so in a private blockchain. Public type blockchains include Bitcoin [24] and Ethereum  [25], whereas private type blockchains include Hyperledger [26].

2.3. Smart Contract

A smart contract is a piece of executable code linked to the necessary memories/tables that are stored as a transaction in the blockchain and are used to perform a predetermined function on a given input. Miners frequently carry out smart contracts for a fixed fee. By knowing the transaction address, it is possible to invoke the smart contract for network members. Smart contracts may provide a high level of assurance due to blockchain’s immutability. In our system, the smart contract function is necessary for mapping the public key to the transaction identity. Hence, we recommend using Ethereum [25] in our design. In the literature, Ethereum has been frequently utilized for creating decentralized applications’ (dApps) smart contracts. It is a well-known blockchain that supports smart contracts. A smart contract can be created and shared by any member of the Ethereum network.

2.4. Elliptic Curve Cryptography

Given a curve y 2 = x 3 + a x + b , along with a distinguished point at infinity O and a prime number q, the Elliptic Curve Cryptography (ECC) E F q is defined as an additive group G over the finite field F q including the set of all ( x , y ) F q × F q such that λ 2 = μ 3 + a μ + b , where a , b F q and 4 a 3 + 27 b 2 m o d q 0 , along with O . It is possible to define subgroups of G including a desired P = { ( λ , μ ) G } which is cyclic and includes all powers of P; P is the generator of this subgroup. The size of the subgroup has defined the order of P which is defined as the smallest positive number n such that n · P = O . For large values of n, given any natural scalar a F q , it is easy to calculate y = a · P (point multiplication) but given y, E F q and P, it is computationally infeasible to compute the multiplicand a. This problem is known as the Elliptic Curve Discrete Logarithm Problem (ECDLP) and is believed to be hard and its difficulty is determined by the size of the elliptic curve subgroup. There is another hard problem over ECC which is called the Elliptic Curve Computational Diffie-Hellman Problem (EC-CDHP) and its aim is to compute a · b · P given a . P , b · P , E F q and P where a , b F q .

2.5. System Model

As shown in Figure 2, we consider a system that includes servers that are used to offer a service for various IoT devices, such as collecting data or providing updates, and so on. When the devices/servers are produced they are also configured and their security parameters are set. As a result, in our concept, the manufacturer also serves as a trusted authority (TA). Because the connection between the devices and the server must be secure, and the IoT devices must only communicate with authorized servers, and the server must also trust the data from trustworthy IoT devices, they must mutually authenticate each other. To ensure a high degree of security, we assume that the security primitives are supported by public keys. Because IoT devices have limited capacity in many applications, they cannot maintain all of the certified public keys, and it is also not practical to place all of the verification traffic on the TA. As a result, we presume that there is a public blockchain that is utilized to validate the public keys. The legitimate public keys are fed into the BC by the TA solely via a smart contract and can be confirmed by any BC member, and the ultimate consensus mechanism might be based on proof of stake, which is more energy-efficient than proof of work. The TA may update the smart contract in this system to add a new identity (which is the public key of an IoT device or a server) or revoke it.

3. Review of Yang et al.’s Scheme

In this section, Yang et al.’s protocol [19] is briefly introduced, followed by a description of the protocol’s weaknesses in terms of security and performance.

3.1. Yang et al.’s Scheme Description

Yang et al. recently proposed a blockchain-based authentication protocol that uses a public blockchain as the source of the public trust and also employs modular square roots as the main source of security in the primitive level [19]. The proposed protocol includes four phases: initialization, registration, authentication, and update and revocation phases.
In the initialization phase of the protocol, the public parameters are announces, i.e., { H ( · ) , M A C ( · ) , E n c ( · ) / D e c ( · ) } . In addition, the blockchain is also established, e.g., based on some existing blockchain systems such as Hyperledger Fabric or Ethereum.
During the registration phase, all devices should be registered to a pre-authenticated device manager (DM), which is assumed to be trusted. Each IoT device, when it is produced by DM, selects two random primes p i and q i such that p i = q i = 3 4 and computes P K i = p i · q i . The device sends its identity S I D i along its public key P K i to DM and it also confirms the validity and updates { P K i , E T i , S I D d m } into the smart contract, through updatePKIT ( P K i , E T i , S I D d m ) , where E T i denotes expiry time of the IoT device and S I D d m refers to the DM’s identity. The device can verify its validity by invoking queryPKIT ( P K i ) . The registration of the server is also similar, where the server’s public key is P K s = p s · q s , its identity is S I D s and its expiry time is E T s .
The authentication phase of the protocol between the i-th IoT device D i and the j-th server S j is initiated by the IoT device, where it first verifies the validity of P K j by invoking the query function queryPKIT ( P K j ) into the blockchain. Assuming that P K j is confirmed by the blockchain, otherwise it should be authenticated with another server, D i obtains the timestamp t s and selects a random integer a such that b p d i 1 2 m o d p d i = b q d i 1 2 m o d q d i = 1 , where b = H ( a , P K j , t s ) . Then, given q d i and p d i , D i calculates the square roots of r 2 = b m o d P K d i , i.e., r 1 , r 2 , r 3 and r 4 , and sets s i = m i n { r 1 , r 2 , r 3 , r 4 } . Next, it computes α d = a 2 m o d P K j , k i = H ( a ) , β d = M A C k i ( α d ) and γ d = E n c k i ( t s , s i , P K d i ) and sends M 1 = { α d , β d , γ d } to S j .
Once received M 1 , S j verifies its correctness to authenticate D i . More precisely, given p s j and q s j , it computes the roots of r 2 = b m o d P K d i , i.e., r 1 , r 2 , r 3 and r 4 , and computes k 1 / 2 / 3 / 4 = H ( r 1 / 2 / 3 / 4 ) to identify the secret key k i as β d = M A C k i ( α d ) . Given k i , it decrypts γ d and obtains ( t s , s i , P K d i ) . Afterward, the validity of t s is verified. Next, S j verifies the validity of P K d i by invoking the query function queryPKIT ( P K j ) into the blockchain. Assuming that P K d i is legitimate, it verifies whether s i 2 = H ( a i , P K j , t s ) m o d P K d i to authenticate the device. To be authenticated by D i , the server S j generates δ s = M A C k s ( t s , s i ) and sends it to the device as M 2 .
D i verifies the received δ s to authenticate S j and sets k i as the session key; otherwise, the authentication process fails.

3.2. On the Security of Yang et al.’s Scheme

Although the scheme proposed by Yang et al. has interesting features and ensures mutual authentication between IoT devices and the server, it is also secure against most attacks assuming the adversary only has access to messages transferred over the public channel. Other attacks, on the other hand, are based on more serious assumptions about the adversary. For example, the security of previous sessions, if the long-term secret key has been leaked, or the security of the session key if the adversary has obtained the ephemeral session-dependent values.
These types of attacks are important because IoT devices are distributed across the network and the adversary may be able to access them and read their memory, which includes long-term secrets, for example. A privileged insider adversary can also leak the server’s data at any time. In this case, the security of previous sessions should be compromised as a result of this damage. In this section, we highlight some critical flaws in Yang et al.’s protocol in this framework.

3.2.1. The Lack of Perfect Forward Secrecy

The protocol provides perfect forward secrecy if compromising the entities’ long-term secrets at time t does not affect the security of the shared session keys at any time t < t .
Let us assume that the adversary eavesdropped on the transferred messages over the public channel in a session, which are M 1 = { α d , β d , γ d } and M 2 = δ s = M A C k s ( t s , s i ) where α d = a 2 m o d P K j , k i = H ( a ) , β d = M A C k i ( α d ) and γ d = E n c k i ( t s , s i , P K d i ) . In addition, assume the adversary is given access to the long-term secrets of the server S j which are p s j and q s j . It is clear that the adversary, given p s j and q s j , can follow the used procedure by the server to retrieve the values. More precisely, she or he computes the roots of r 2 = b m o d P K d i , i.e. r 1 , r 2 , r 3 and r 4 , and computes k 1 / 2 / 3 / 4 = H ( r 1 / 2 / 3 / 4 ) to identify the secret key k i as β d = M A C k i ( α d ) . Given k i , it decrypts γ d and obtains ( t s , s i , P K d i ) . Afterward, the adversary verifies whether s i 2 = ? H ( a i , P K j , t s ) m o d P K d i to make sure whether he or she retrieved the values correctly. It shows this protocol does not provide perfect forward secrecy.

3.2.2. Known Session-Specific Temporary Information Attack

Let us assume that the adversary knows the session-specific temporary values. In a secure protocol, it should not affect the security of the shared session key. Hence, we evaluate the security of Yang et al.’s scheme against the Known Session-specific Temporary Information Attack (KSTIA). More precisely, if the session’s short-term secrets are accidentally exposed to an attacker, the security of the produced session key should be unaffected. However, in Yang et al.’s scheme, the session key is computed as k i = H ( a ) , where a is a selected random integer by the device D i . It is clear that exposing a leads to direct leakage of the session key k i . Hence, this protocol is valuable to KSTIA.

3.3. On the Efficiency of Yang et al.’s Scheme

Following description of Yang et al.’s scheme, to verify M 1 , S j computes the roots of r 2 = b m o d P K d i , i.e., r 1 , r 2 , r 3 and r 4 , and computes k 1 / 2 / 3 / 4 = H ( r 1 / 2 / 3 / 4 ) to identify the secret key k i as β d = M A C k i ( α d ) . However, it is possible to verify the correctness of the driven roots after decryption of γ d , where ( t s , s i , P K d i ) is obtained. Afterward, the validity of t s and s i 2 = H ( a i , P K j , t s ) m o d P K d i are verified. Next, S j verifies the validity of P K d i by invoking the query function queryPKIT ( P K j ) into the blockchain to authenticate the device. To be authenticated by D i , the server S j generates δ s = M A C k s ( t s , s i ) and sends it to the device as M 2 . In this way, it is not necessary to force the end device to also support MAC function and it also reduces the communication cost, because M 1 can be redesigned as M 1 = { α d , γ d } . Hence, it shows that Yang et al.’s scheme is not optimum in the term of the used primitives and communication cost.

4. BCmECC, a Blockchain Mounted ECC Based Scheme

In this section, we attempt to design a blockchain-mounted ECC-based protocol called BCmECC, which does not have the shortcomings of the previous protocol, i.e., Yang et al.’s, and performs better in terms of performance, communication, and computational costs.

4.1. Initialization Phase

The smart contract is initiated in this phase of the proposed blockchain mounted ECC-based authentication protocol, named BCmECC, and the T A releases the system parameters, i.e., { E q ( c , d ) , q , P , h ( · ) } and its public key P K T A = s k T A · P while keeping s k T A secret. We also assume that each device has an embedded serial number S I D i and an expiring lifetime E L T i that is bounded by its S I D i . The smart contract is adapted from [19] and depicted in Algorithm 1.

4.2. Registration Phase of the Protocol

In the registration phase of BCmECC, each IoT device D i , when it is produced by DM, selects a private key s k i and computes its public key as P K i = s k i · P . The device sends its identity S I D i along its public key P K i to DM and it also confirms the validity and updates { P K i , E T i , S I D d m } into the smart contract, through updatePKIT ( P K i , E T i , S I D d m ) . The device can verify its validity by invoking queryPKIT ( P K i ) . The registration of the server is also similar, where the server public key is P K j = s k j · P , its identity is S I D j and its expiry time is E T j .

4.3. Mutual Authentication Phase of the Protocol

This phase of BCmECC is represented in Figure 3. As it is also depicted in this figure, to connect with a server S j , assuming that the device knows its public key P K j , the device sends queryPKIT ( P K j ) to BC , extracts t s , generates a random number a, computes k i = H ( t s , a · s k i · P K j ) , α d = a · P K i , β d = E n c k i ( t s , P K i , H ( a · s k i · P K j , t s ) ) and sends M 1 = ( t s , α d , β d ) to the server S j over the public channel.
Once received M 1 , the server verifies t s , computes k s = H ( t s , s k j · α d ) and ( t s , P K i , P K j , H ( a · s k i · P K j , t s ) ) = D e c k s ( β d ) , verifies t s = t s , P K j = P K j and H ( a · s k i · P K j , t s ) = ? H ( s k j · α d , t s ) to accept the request and send queryPKIT ( P K i ) to BC . If P K i is valid, it generates a random number b, computes λ s = b · P K j and γ s = H ( b · H ( t s , k s ) · s k j · α d ) and sends M 2 = ( λ s , γ s ) to the device D i over the public channel. The device D i verifies the received γ s = ? H ( a · H ( t s , k i ) · s k i · λ s ) to authenticate S j . Assuming the authentication phase was successful, the session key is computed on the server and D i sides as S K t s = H ( t s , b · s k j α d ) and S K t s = H ( t s , a · s k i λ s ) , which are clearly the same.
Algorithm 1. A smart contract-based management of the entities’ public key information using Public Key Information Table (PKIT) which has been adapted from the used smart contract of [19].
  • Require: Function name and the invoked parameters and address of device manager (DM).
  • Ensure: Setting up functions structure PKI //Define the structure of components in PKIT
      1:
    byte20[2] P K ;
      2:
    int ET;                                                                 //  the expiry time
      3:
    byte20 SID;  
      4:
function u p d a t e P K I T ( P K , E T , S I D )    //Invoked by DM to update public key information
      5:
if D M = = m s g . s e n d e r then
      6:
    if  P K I [ i ] . P K P K I T  then
      7:
         P K I [ i ] : P K P K ;
      8:
         P K I [ i ] : E T E T ;
      9:
         P K I [ i ] : S I D S I D ;
      10:
        return 1;
      11:
    else
      12:
         + 1 ;
      13:
         P K I [ i ] : P K P K ;
      14:
         P K I [ i ] : E T E T ;
      15:
         P K I [ i ] : S I D S I D ;
      16:
        return 1;
      17:
else
      18:
    return 0;
      19:
function q u e r y P K I T ( P K )       //Invoked by DM to update public key information
      20:
if D M = = m s g . s e n d e r then
      21:
    if  P K I [ i ] . P K P K I T && P K I [ i ] . E T is fresh then
      22:
        return 1;
      23:
    else
      24:
        return 0;
      25:
else
      26:
    return 0;
      27:
function r e v o k e P K I T ( P K , S I D )        //Invoked by DM to revoke an IoT device or server
      28:
if D M = = m s g . s e n d e r then
      29:
    if  P K I [ i ] . P K P K I T  then
      30:
         P K I T P K I T / P K I [ i ] ;
      31:
         1 ;
      32:
        return 1;
      33:
    else
      34:
        return 0;
      35:
else
      36:
    return 0;

4.4. Update and Revocation Phase of the Protocol

Once in a while, it may be required to update the IoT device’s public key or revoke it before its expiration time. For the revocation, the TA can revoke the target device/server ( D i / S j ) from the smart contract by invoking the revokePKIT ( P K i / j , S I D d m ) query.
To update the public key of a device/server ( D i / S j ), it should be authenticated into the TA, and sends the new public key to the TA. Next, the TA revokes the previous record from the smart contract by revokePKIT ( P K i / j o l d , S I D d m ) and then updates the smart contract by updatePKIT ( P K i / j n e w , E T i , S I D d m ) . The authentication phase of D i / S j to TA is depicted in Figure 4.
To start the authentication phase, D i / S j selects a private key s k i / j n e w and computes its public key as P K i / j n e w = s k i / j n e w · P . Then, it extracts t s , generates a random value a, computes k i / j = H ( t s , a · s k i / j · P K T A ) , α d = a · P K i / j , β d = E n c k i / j ( a , P K i / j , P K T A , P K i / j n e w , S I D i / j ) and sends M 1 = ( t s , α d , β d ) to TA over the public channel.
Once received M 1 , the TA verifies t s , computes k s = H ( t s , s k T A j · α d ) and ( a , P K i / j , P K T A , P K i / j n e w , S I D i / j ) = D e c k s ( β d ) , verifies t s = t s , P K T A = P K T A , S I D i / j corresponds to P K i / j and k s = H ( t s , a · s k T A · P K i / j ) to proceed the request. Then, it sends queryPKIT ( P K i / j ) to BC . If P K i / j is valid then TA computes γ T A = H ( t s i , P K i / j , P K i / j n e w , P K i / j o l d , k s ) and sends M 2 = ( λ s , γ s ) to D i / S j over the public channel.
The device D i / S j verifies the received γ T A = H ( t s i , P K i / j , P K i / j n e w , P K i / j o l d , k s ) to authenticate TA. Next, it sends θ d = γ T A · ( s k i / j n e w + s k i / j o l d ) · P K T A to TA as M 3 .
Once received M 3 , TA verifies θ d = γ T A · s k T A · ( P K i / j n e w + P K i / j o l d ) to accept the request and send revokePKIT ( P K i / j o l d , S I D d m ) to BC and then updates the smart contract by updatePKIT ( P K i / j n e w , E T i , S I D d m ) .
After a while, D i / S j sends queryPKIT ( P K i / j ) to BC to make sure it has been updated on the smart contract by TA and removes ( s k i / j o l d ) , ( P K i / j o l d ) from its memory. Otherwise, it means that the protocol’s run was not successful and should be re-launched.

5. Security Analysis of BCmECC

In general, there are two methods for analyzing and proving the security of security protocols. Methods can be formal or informal. Informal methods are those that use creativity, knowledge, and innovative methods to find a security flaw or prove the protocol’s security. To discover protocol security vulnerabilities or prove its security, manual formal methods such as BAN logic  [27] or automatic formal methods such as Scyther [28] are used.
In this section, we evaluate the security of BCmECC against various attacks and also verify its security both informally and formally using widely accepted formal methods, i.e. Scyther tool and BAN logic.

5.1. Formal Security Analysis

5.1.1. BAN Logic

Several phases are involved in the security evaluation of BCmECC employing BAN logic [27]. To begin, the messages of BCmECC are described in BAN logic form, see Table 2, where we use BAN logic notations depicted in Table 3 to show messages. Following that, the messages of BCmECC are idealized. Messages that are too simple or do not inspire confidence are removed at this stage. Table 4 depicts the idealized form of protocol messages. Following that, BCmECC’s security assumptions and security goals are stated. The assumptions and security goals are shown in Table 5. The security goals should then be deduced from an ideal form and assumptions using BAN logic rules. As shown in Table 6, utilizing A 7 and I M 2 based on the F 2 rule of BAN logic, we deduce that D 1 : D i | S j | { λ s , t s , a } . Given D 1 and A 1 , and using the F 6 rule of BAN logic, we can derive that D 2 : D i | { λ s , t s , a } . With D 1 and D 2 based on F 3 , we obtain D 3 : D i | S j | { λ s , t s , a } . Using D 3 and F 5 , we get D 4 : D i | λ s , D 5 : D i | t s , and D 6 : D i | a . We calculated D 7 : D i | ( a . s k i . λ s ) using A 6 , D 4 : D i | λ s , and D 6 : D i | a based on F 1 . We get D 8 : D i | ( t s , a . s k i . λ s ) from D 7 and D 5 based on F 1 . Using F 4 , we inferred that D 9 : D i | H ( t s , a . s k i . λ s ) is the same session secret key, i.e. D 9 : D i | S K as G 1 . It verifies the security goal G 1 , indicating that D i believes a session key has been created between itself and the server. We can conclude D 10 : S j | D i | { t s , P K i , α d } using A 8 and I M 1 based on the F 2 rule of BAN logic. Given A 2 , we may derive from the F 6 rule of BAN logic that D 11 : S j | { t s , P K i , α d } . Taking into account D 10 and D 11 based on F 3 , we obtain D 12 : S j | D i | { t s , P K i , α d } . We get D 13 : S j | t s , D 14 : S j | P K i , D 15 : S j | α d from D 12 based on F 5 . Using A 5 , D 15 : S j | α d , and A 4 based on F 1 , we deduced D 16 : S j | ( b . s k j . α d ) . Given D 13 and D 16 , we get D 17 : S j | ( t s , b . s k j . α d ) . Using F 4 , we inferred that D 18 : S j | H ( t s , b . s k j . α d ) is the same session secret key as G 2 , i.e., D 18 : S j | S K . It confirms the security goal G 2 , implying that S j believes a session key has been created between itself and D i .

5.1.2. Scyther

In this section, we demonstrate that BCmECC meets all of the protocol’s security objectives using the Scyther tool [28]. Scyther evaluates all forms of security claims in the protocol and, if any type of attack is discovered, the attack situation is graphically displayed. To be more specific, the Scyther studies secrecy and authentication in security protocols. To that aim, BCmECC is described in the Security Protocol Description Language (SPDL), as seen in Figure 5, and examined using the Scyther tool. The security verification result of the mutual authentication phase of BCmECC is likewise presented in Figure 6.

5.2. Informal Security Analysis

It is common to argue the protocol’s security against various attacks in an informal manner to confirm its security. In this section, we argue BCmECC’s security against well-known attacks in order to demonstrate its security strengths.

5.2.1. Replay Attack

To do a replay attack, the adversary tries to impersonate a protocol’s party by eavesdropping on a session of the protocol between legitimate entities and later broadcasting the stored messages to be authenticated as a legitimate party. In the authentication phase of BCmECC, the transferred messages over the public channel are as follows:
α d = a · P K i β d = E n c k i ( t s , P K i , H ( a · s k i · P K j , t s ) ) λ s = b · P K j γ s = H ( t s i , P K j , P K i , k s )
where k i = k s = H ( t s , a · s k i · P K j ) . Since the encryption/decryption key is a factor of the timestamp t s , the eavesdropped message at the time t cannot be used in any later time t as it is. In addition, to generate a valid key k i = k s = H ( t s , a · s k i · P K j ) , the adversary should compute a · s k i · P K j without the knowledge of s k i / j which is as hard as ECDLP. Hence, the proposed protocol is secure against a replay attack.

5.2.2. Impersonation Attack

To impersonate a target protocol entity, the adversary must either perform a replay attack or generate valid messages that can be accepted by a protocol party. However, in the case of BCmECC, we argued in Section 5.2.1 that a replay attack is not feasible. The adversary, on the other hand, is unable to generate valid messages because to compute valid β d = E n c k i ( t s , P K i , H ( a · s k i · P K j , t s ) ) or λ s = b · P K j and γ s = H ( b · H ( t s , k s ) · s k j · α d ) the adversary should calculate k i = k s = H ( t s , a · s k i · P K j ) successfully, which requires computing s k i / j · P K j / i , given P K i and P K j . However, computing s k i / j · P K j / i form s k i · P and s k j · P equals to solving ECDLP again. It means that BCmECC is secure against impersonation attacks.

5.2.3. Traceability and Anonymity

To trace a protocol party, the adversary should be able to link the transferred messages over different sessions, in which a specific entity has been involved, together or to the target entity. In the proposed protocol, the transferred messages are α d = a · P K i , β d = E n c k i ( t s , P K i , H ( a · s k i · P K j , t s ) ) , λ s = b · P K j and γ s = H ( b · H ( t s , k s ) · s k j · α d ) , where a is a random value which is generated in the session by D i and randomizes α d , and β d directly, because it is used in their computation. In addition, γ s = H ( b · H ( t s , k s ) · s k j · α d ) is also a factor of a, because k s = H ( t s , a · s k i · P K j ) . Hence, all the transferred messages are randomized by a random value which is changed from a session to another session. It guarantees a protocol’s security against traceability attacks. It should be noted that, similar to most of the other blockchain-based protocols, it is possible to trace a node’s public key (not its real identity) assuming that the adversary can also control the queries toward the smart contract of blockchain.

5.2.4. Secret Disclosure Attack

The secret parameter in the IoT device is its secret key s k i and the secret of the server is s k j . However, neither of them is transferred in the plain form over the channel. Hence, it is not feasible for the adversary to extract them from the eavesdropped values from the channel. The session key is also computed as k i = k s = H ( t s , a · s k i · P K j ) . However, again the adversary cannot compute it given P K i , P K j , α d = a · P K i , β d = E n c k i ( t s , P K i , H ( a · s k i · P K j , t s ) ) , λ s = b · P K j and γ s = H ( b · H ( t s , k s ) · s k j · α d ) without contradicting ECDLP, which is not feasible in practice. Hence, BCmECC is secure against secret disclosure attacks.

5.2.5. Permanent de-Synchronization Attack

To permanently de-synchronize a protocol party, the adversary could force them to update their shared values differently, as seen in [29]. However, in the authentication phase of BCmECC, the protocol’s parties do not update the shared values, hence, it is not possible to de-synchronize them in this phase.
It may be possible to desynchronize a legitimate D i / S j in the update phase of the protocol. However, the process of that phase is almost similar to the authentication phase, and the adversary should be able to impersonate the target D i / S j to encourage TA to update its public key on the blockchain. However, in that case the adversary should generate a valid θ d = γ T A · ( s k i / j n e w + s k i / j o l d ) · P K T A which requires the knowledge of s k i / j o l d , which is not available to the adversary and extracting it form P K i / j contradicting ECDLP, which is not feasible in practice. Hence, BCmECC is secure against de-synchronization attack.

5.2.6. Man-in-the-Middle Attack

Given that hash functions ensure the integrity of all messages and timestamps govern session time, any message tampering or unexpected delay by a man-in-the-middle adversary will have a high likelihood of being discovered. As a result, BCmECC is safe from man-in-the-middle attacks.

5.2.7. Insider Adversary

Let us assume a malicious server S j , which has been contacted by D i , aims to impersonate D i toward another server S j S j or toward TA. To impersonate D i toward S j , the adversary should compute
α d = a · P K i β d = E n c k i ( a , P K i , P K j , H ( a · s k i · P K j , t s ) ) k i = H ( t s , a · s k i · P K j )
Although α d can be computed easily or even reused from the previous sessions, computing k i = H ( t s , a · s k i · P K j ) is challenging because the adversary should compute a · s k i · P K j given a · s k i · P K j , P K j , P K j and P K i and requires to contradict ECDLP, which is not feasible in practice. However, if S j colludes with S j they can compute a · s k i · P K j from the given information. However, in this case S j also learns s k j or vice versa which is not acceptable. To impersonate D i toward TA, the insider adversary should compute α d = a · P K i / j , β d = E n c k i / j ( a , P K i / j , P K j , H ( a · s k i · P K j , t s ) ) and θ d = γ T A · ( s k i / j n e w + s k i / j o l d ) · P K T A from the above mentioned information and P K T A which again infeasible. Hence, BCmECC is secure against insider adversary. It should be noted we consider T A completely honest. Otherwise it can mislead whole the network by injecting wrong information in the smart-contract.

5.2.8. Perfect Forward Secrecy

In the forward secrecy analysis, the adversary should not be able to release the ephemeral session key of the session t assuming that it has the long-term key of the protocol at time t . In BCmECC, the session key is computed as S K t s = H ( t s , b · s k j α d ) = H ( t s , a · s k i λ s ) and the adversary has access to P K i , P K j , α d = a · P K i , β d = E n c k i ( t s , P K i , H ( a · s k i · P K j , t s ) ) , λ s = b · P K j and γ s = H ( b · H ( t s , k s ) · s k j · α d ) and also s k i and s k j . In this case the adversary’s main challenge is to compute a · b · s k i · s k j · P . However, it could achieve a · P and b · P not a · b · P from that information without contradicting ECDLP, which is not feasible in practice. Hence, BCmECC provides perfect forward secrecy.

5.2.9. Known Session-Specific Temporary Information Attack

Let us assume the adversary knows the session specific temporary values of BCmECC, i.e., a, b and t s , and tries to compute the shared session key. To extract the session key, the adversary should compute S K t s = H ( t s , b · s k j α d ) = H ( t s , a · s k i λ s ) . However, similar to the case of perfect forward secrecy, the main challenge is the computation of a · b · s k i · s k j · P from the available messages over public channel and also a, b and t s . Given that the adversary cannot compute s k i · s k j · P from P K i and P K j , it also cannot compute a · b · s k i · s k j · P without contradicting ECDLP, which is not feasible in practice. Hence, BCmECC provides perfect forward secrecy. Hence, this protocol is secure against KSTIA.

6. On the Efficiency of BCmECC

Given that BCmECC is inspired by the proposed scheme by Yang et al. [19], we discuss the advantages of the BCmECC over that scheme to ensure its efficiency, besides its better security.
In the term of the required primitives, the client and the server of Yang et al.’s scheme [19] should support modular square roots computation, symmetric encryption, one-way hash function, and also a message authentication code. BCmECC requires ECC, symmetric encryption and a one-way hash function.
In terms of the communication cost, thanks to the short length of the key in the ECC compared to modular square roots computation for the same security margin, we decreased the communication cost dramatically. More precisely, to achieve an 80/112/128-bit key in a symmetric algorithm, the parameter length should be 1024/2048/3072 in modular square roots computation, while 160/256/384-bit ECC provides the same security levels. Therefore, to provide a 128-bit level of security, we should use a 256-bit hash function such as SHA-256 [30], a 256-bit curve, and a 128-bit block cipher, e.g., AES-128 [31]. Hence, assuming that we use 64 bits to represent t s , the length of the transferred messages over mutual authentication phase of BCmECC are determined as | M 1 | = | ( t s , α d , β d ) | = 64 + 512 + ( 64 + 512 + 256 ) = 1408 and | M 2 | = | ( λ s , γ s ) | = 512 + 256 = 768 bits. While in Yang et al. for the same security level, if we assume it is secure, the length of the transferred messages over its mutual authentication phase are determined as | M 1 | = | ( α d , β d , γ d ) | = 3072 + 256 + 64 + 3072 + 3072 = 9536 and | M 2 | = | δ s | = 256 bits.

7. Conclusions and Future Works

In this paper, we first describe the security and performance flaws of the authentication protocol proposed by Yang et al. based on the blockchain. Then, inspired by this protocol and utilizing elliptic curve cryptography (ECC) in the blockchain’s bed, the BCmECC protocol was proposed. Informal and formal security assessments of BCmECC by the BAN logic and the Scyther automatic security verifier tool show that it is more secure than its predecessors. In addition, the performance evaluation shows that, in addition to increasing security, the protocol has reduced communication and computational costs.
While using blockchain increases the public trust in the authentication process and also decreases the required resources in the devices because it does not require to keeping of the certificates of all parties assuming that there is no reliable connection to the TA, sending the public key of an entity to Blockchain leads to a sort of traceability. It should be noted that all public Bitcoin transactions are also traceable and archived indefinitely on the bitcoin network. Although Bitcoin addresses are the sole information utilized to identify where Bitcoin is allocated and where it is delivered, the utilized addresses reveal the history of all transactions in which they are engaged. Since everyone has access to the inventory and all transactions for each address, so the Bitcoin also does not provide full anonymity. Therefore, it remains open research to use the blockchain’s advantage while also providing full anonymity. Although in the proposed protocol it is possible to update the public key once in a while to break the traceability sequence, it needs a new approach to design such a protocol, which may be costly.

Author Contributions

J.L.: Conceptualization, Methodology, Validation, Writing, Funding; A.M.R.: Experimentation, Validation, Writing—review & editing, S.A. Experimentation, Validation, review & editing, N.B. Conceptualization, Methodology, Experimentation, Validation, Writing—review & editing, M.S. Experimentation, Validation, Writing—review & editing; O.H.A. Experimentation, Designing, Validation, Writing—review & editing and M.H.: Methodology, Designing, Experimentation, Validation, Supervision, review & editing. All authors have read and agreed to the published version of the manuscript.

Funding

The result was created with the use of institutional support for long-term conceptual development of research of the University of Finance and Administration.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

Not applicable.

Acknowledgments

The authors would like to thank the anonymous reviewers for their thorough reading of this paper, as well as their many insightful comments and suggestions.

Conflicts of Interest

The authors declare no conflict of interest. The founding sponsors had no role in the design of the study; in the collection, analyses, or interpretation of data; in the writing of the manuscript, and in the decision to publish the results.

Abbreviations

The following abbreviations are used in this manuscript:
IoTInternet of Things
TTPTrusted Third Party
DDoSDistributed Denial of Service
ECCElliptic Curve Cryptography
ECDLPElliptic Curve Discrete Logarithm Problem
EC-CDHPElliptic Curve Computational Diffie-Hellman Problem
KSTIAKnown Session-specific Temporary Information Attack
PKITPublic Key Information Table
SPDLSecurity Protocol Description Language
BANBurrows Abadi Needham
BCBlockchain
dAppsDecentralized Applications

References

  1. Safkhani, M.; Rostampour, S.; Bendavid, Y.; Bagheri, N. IoT in medical & pharmaceutical: Designing lightweight RFID security protocols for ensuring supply chain integrity. Comput. Netw. 2020, 181, 107558. [Google Scholar] [CrossRef]
  2. FDA. Counterfeit Medicine. Available online: https://www.fda.gov/drugs/buying-using-medicine-safely/counterfeit-medicine (accessed on 7 June 2020).
  3. Behner, P.; Hecht, M.L.; Wahl, F. Fighting Counterfeit Pharmaceuticals. Available online: https://www.strategyand.pwc.com/gx/en/insights/2017/fighting-counterfeit-pharmaceuticals/fighting-counterfeit-pharmaceuticals.pdf (accessed on 7 June 2020).
  4. Hosseinzadeh, M.; Koohpayehzadeh, J.; Bali, A.O.; Asghari, P.; Souri, A.; Mazaherinezhad, A.; Bohlouli, M.; Rawassizadeh, R. A diagnostic prediction model for chronic kidney disease in internet of things platform. Multimed. Tools Appl. 2021, 80, 16933–16950. [Google Scholar] [CrossRef]
  5. Sadrishojaei, M.; Navimipour, N.J.; Reshadi, M.; Hosseinzadeh, M. A New Preventive Routing Method Based on Clustering and Location Prediction in the Mobile Internet of Things. IEEE Internet Things J. 2021, 8, 10652–10664. [Google Scholar] [CrossRef]
  6. Bendavid, Y. RFID-enabled applications to improve the delivery of healthcare services: A typology and supporting technologies. J. Med. Biol. Eng. 2013, 33, 433–442. [Google Scholar]
  7. Rathee, G.; Balasaraswathi, M.; Chandran, K.P.; Gupta, S.D.; Boopathi, C. A secure IoT sensors communication in industry 4.0 using blockchain technology. J. Ambient. Intell. Humaniz. Comput. 2020, 12, 533–545. [Google Scholar] [CrossRef]
  8. Safkhani, M.; Bagheri, N. Cryptanalysis of two recently proposed ultralightweight authentication protocol for IoT. arXiv 2019, arXiv:1907.11322. [Google Scholar]
  9. Rostampour, S.; Safkhani, M.; Bendavid, Y.; Bagheri, N. ECCbAP: A secure ECC-based authentication protocol for IoT edge devices. Pervasive Mob. Comput. 2020, 67, 101194. [Google Scholar] [CrossRef]
  10. Safkhani, M.; Bagheri, N.; Kumari, S.; Tavakoli, H.; Kumar, S.; Chen, J. RESEAP: An ECC-Based Authentication and Key Agreement Scheme for IoT Applications. IEEE Access 2020, 8, 200851–200862. [Google Scholar] [CrossRef]
  11. Gupta, S.; Malhotra, V.; Singh, S.N. Securing IoT-Driven Remote Healthcare Data Through Blockchain. In Advances in Data and Information Sciences; Springer: Berlin/Heidelberg, Germany, 2020; pp. 47–56. [Google Scholar]
  12. Lin, C.; He, D.; Huang, X.; Kumar, N.; Choo, K.K.R. BCPPA: A blockchain-based conditional privacy-preserving authentication protocol for vehicular ad hoc networks. IEEE Trans. Intell. Transp. Syst. 2020. [Google Scholar] [CrossRef]
  13. Ma, Z.; Meng, J.; Wang, J.; Shan, Z. Blockchain-Based Decentralized Authentication Modeling Scheme in Edge and IoT Environment. IEEE Internet Things J. 2021, 8, 2116–2123. [Google Scholar] [CrossRef]
  14. Panda, S.S.; Jena, D.; Mohanta, B.K.; Ramasubbareddy, S.; Daneshmand, M.; Gandomi, A.H. Authentication and Key Management in Distributed IoT Using Blockchain Technology. IEEE Internet Things J. 2021, 8, 12947–12954. [Google Scholar] [CrossRef]
  15. Zhang, Y.; Li, B.; Liu, B.; Hu, Y.; Zheng, H. A Privacy-Aware PUFs-Based Multiserver Authentication Protocol in Cloud-Edge IoT Systems Using Blockchain. IEEE Internet Things J. 2021, 8, 13958–13974. [Google Scholar] [CrossRef]
  16. Wang, X.; Garg, S.; Lin, H.; Piran, M.J.; Hu, J.; Hossain, M.S. Enabling Secure Authentication in Industrial IoT With Transfer Learning Empowered Blockchain. IEEE Trans. Ind. Inform. 2021, 17, 7725–7733. [Google Scholar] [CrossRef]
  17. Shen, M.; Liu, H.; Zhu, L.; Xu, K.; Yu, H.; Du, X.; Guizani, M. Blockchain-Assisted Secure Device Authentication for Cross-Domain Industrial IoT. IEEE J. Sel. Areas Commun. 2020, 38, 942–954. [Google Scholar] [CrossRef]
  18. Hong, S. P2P networking based internet of things (IoT) sensor node authentication by Blockchain. Netw. Appl. 2020, 13, 579–589. [Google Scholar] [CrossRef]
  19. Yang, X.; Yang, X.; Yi, X.; Khalil, I.; Zhou, X.; He, D.; Huang, X.; Nepal, S. Blockchain-Based Secure and Lightweight Authentication for Internet of Things. IEEE Internet Things J. 2021. [Google Scholar] [CrossRef]
  20. Yavari, M.; Safkhani, M.; Kumari, S.; Kumar, S.; Chen, C. An Improved Blockchain-Based Authentication Protocol for IoT Network Management. Secur. Commun. Netw. 2020, 2020, 8836214. [Google Scholar] [CrossRef]
  21. Tsang, Y.; Wu, C.; Ip, W.; Shiau, W.L. Exploring the intellectual cores of the blockchain—Internet of Things (BIoT). J. Enterp. Inf. Manag. 2021, 34, 1287–1317. [Google Scholar] [CrossRef]
  22. Bhushan, B.; Sahoo, C.; Sinha, P.; Khamparia, A. Unification of Blockchain and Internet of Things (BIoT): Requirements, working model, challenges and future directions. Wirel. Netw. 2021, 27, 55–90. [Google Scholar] [CrossRef]
  23. Rahmani, A.M.; Mohammadi, M.; Rashidi, S.; Lansky, J.; Mildeová, S.; Safkhani, M.; Kumari, S.; Hosseinzadeh, M. Questioning the Security of Three Recent Authentication and Key Agreement Protocols. IEEE Access 2021, 9, 98204–98217. [Google Scholar] [CrossRef]
  24. Nakamoto, S. Bitcoin: A peer-to-peer electronic cash system. Decentralized Bus. Rev. 2008, 21260. [Google Scholar]
  25. Buterin, V. Ethereum white paper. Github Repos. 2013, 1, 22–23. [Google Scholar]
  26. Hyperledger. Open Source Blockchain Technologies. Available online: https://www.hyperledger.org/ (accessed on 17 September 2020).
  27. Burrows, M.; Abadi, M.; Needham, R.M. A logic of authentication. Proc. R. Soc. Lond. Math. Phys. Sci. 1989, 426, 233–271. [Google Scholar]
  28. Cremers, C.J.F. The Scyther Tool: Verification, Falsification, and Analysis of Security Protocols. In Computer Aided Verification; Springer: Berlin/Heidelberg, Germany, 2008; pp. 414–418. [Google Scholar]
  29. Safkhani, M.; Bagheri, N. Generalized Desynchronization Attack on UMAP: Application to RCIA, KMAP, SLAP and SASI+ protocols. IACR Cryptol. Arch. 2016, 2016, 905. [Google Scholar]
  30. Dang, Q. Changes in federal information processing standard (FIPS) 180-4, secure hash standard. Cryptologia 2013, 37, 69–73. [Google Scholar] [CrossRef]
  31. Daemen, J.; Rijmen, V. The Design of Rijndael—The Advanced Encryption Standard (AES), 2nd ed.; Information Security and Cryptography; Springer: Berlin/Heidelberg, Germany, 2020. [Google Scholar] [CrossRef]
Figure 1. A simple example of blockchain ledger [24].
Figure 1. A simple example of blockchain ledger [24].
Mathematics 09 03241 g001
Figure 2. The system model of the considered fusion of blockchain and the Internet of Things.
Figure 2. The system model of the considered fusion of blockchain and the Internet of Things.
Mathematics 09 03241 g002
Figure 3. Mutual authentication phase of BCmECC scheme to share a session key between D i and S j .
Figure 3. Mutual authentication phase of BCmECC scheme to share a session key between D i and S j .
Mathematics 09 03241 g003
Figure 4. Mutual authentication phase between D i / S j and TA of BCmECC scheme to update P K i / j .
Figure 4. Mutual authentication phase between D i / S j and TA of BCmECC scheme to update P K i / j .
Mathematics 09 03241 g004
Figure 5. SPDL implementation of the mutual authentication phase of BCmECC.
Figure 5. SPDL implementation of the mutual authentication phase of BCmECC.
Mathematics 09 03241 g005
Figure 6. Security verification of mutual authentication phase of BCmECC through Scyther.
Figure 6. Security verification of mutual authentication phase of BCmECC through Scyther.
Mathematics 09 03241 g006
Table 1. List of used notations.
Table 1. List of used notations.
SymbolDescription
EElliptic Curve Cryptography
G A finite prime group
PGenerator point of a large group G
qA large prime number
s k Secret key
P K Public key
T A A trusted authority with public key of P K T A = s k T A · P and secret key of s k T A
D i / S j i / j -th IoT device/server
S I D The unique identifier
a / b Random number
H ( · ) One-way hash functions
t s Timestamp
x · P Multiplying a point P by scalar x
A = ? B Comparison of A and B
S K The shared session key
E L T i D i ’s expire life time that is bounded by its S I D i
Table 2. Expressing the messages of BCmECC in BAN logic.
Table 2. Expressing the messages of BCmECC in BAN logic.
No.Description
M 1 : S j t s , α d , β d = { t s , P K i , H ( a · s k i · P K j , t s ) } k i = { t s , P K i , H ( a · s k j · P K i , t s ) } k i = { t s , P K i , H ( s k j · α d , t s ) } k i = { t s , P K i , α d } K i
M 2 : D i λ s , γ s = H ( b . H ( t s , k s ) . s k j . α d ) = H ( b . H ( t s , K s ) . s k j . a . P K i ) = H ( b . H ( t s , k s ) . P K j . a . s k i ) = H ( λ s . H ( t s , k s ) . a . s k i ) = { λ s , t s , a } k s
Table 3. Some of BAN logic notations and rules used in this paper.
Table 3. Some of BAN logic notations and rules used in this paper.
NotationsDescription
( X ) X is fresh
{ X } K The symmetric encryption of X with K as the key
P X P sees the message X
P K Q K is secretly shared between P and Q
F 1 : P | X , P | Y P | ( X , Y ) If P believes the message X and also believes Y then it is entitled that P believes ( X , Y )
F 2 : P | P K Q , P { X } K P | Q | X If P believes the K is securely shared between itself and Q and also receives the { X } K , then it is deduced that P believes Q conveys message X
F 3 : P | X , P | Q | X P | Q | X If P believes the X is fresh and also believes that the Q has sent X, then it is entitled that P believes Q believes X
F 4 : P | X P | H ( X ) If P believes the message X then it is entitled that P believes the hash value of X i.e., H ( X )
F 5 : P | ( X , Y ) P | X , P | Y If P believes in a set of messages i.e., ( X , Y ) , then it is deduced P believes in each of them
F 6 : P | ( X ) P | ( X , Y ) If P believes freshness of X, then it is deduced P believes freshness of any combination of it
Table 4. Idealization of the messages of BCmECC in BAN logic.
Table 4. Idealization of the messages of BCmECC in BAN logic.
No.Description
I M 1 : S j t s , α d , β d = { t s , P K i , α d , s k i , P K j , H ( a · s k i · P K j , t s ) } k i = { t s , P K i , α d } K i
I M 2 : D i λ s , γ s = H ( b . H ( t s , k s ) . s k j . α d ) = H ( b . H ( t s , k s ) . s k j . a . P K i ) = H ( b . H ( t s , k s ) . P K j . a . s k i ) = H ( λ s . H ( t s , k s ) . a . s k i ) = { λ s , t s , a } k s
Table 5. BCmECC’s assumptions and security goals.
Table 5. BCmECC’s assumptions and security goals.
A/GDescriptionA/GoalDescription
A 1 D i | t s A 2 S j | t s
A 3 D i | a A 4 S j | b
A 5 S j | s k j A 6 D i | s k i
A 7 D i | D i k i , k s S j A 8 S j | S j k i , k s D i
G 1 D i | S K G 2 S j | S K
Table 6. Deduction of BCmECC’s security goals.
Table 6. Deduction of BCmECC’s security goals.
Assumptions, Messages and RulesDeduction
A 7 , I M 2 based on F 2 D 1 : D i | S j | { λ s , t s , a }
A 1 , D 1 based on F 6 D 2 : D i | { λ s , t s , a }
D 1 , D 2 based on F 3 D 3 : D i | S j | { λ s , t s , a }
D 3 based on F 5 D 4 : D i | λ s , D 5 : D i | t s , D 6 : D i | a
A 6 , D 4 , D 6 based on F 1 D 7 : D i | ( a . s k i . λ s )
D 7 , D 5 based on F 1 D 8 : D i | ( t s , a . s k i . λ s )
D 8 based on F 4 D 9 : D i | H ( t s , a . s k i . λ s ) = > D i | S K = G 1
A 8 , I M 1 based on F 2 D 10 : S j | D i | { t s , P K i , α d }
A 2 based on F 6 D 11 : S j | { t s , P K i , α d }
D 10 , D 11 based on F 3 D 12 : S j | D i | { t s , P K i , α d }
D 12 based on F 5 D 13 : S j | t s , D 14 : S j | P K i , D 15 : S j | α d
A 5 , A 4 , D 15 based on F 1 D 16 : S j | ( b . s k j . α d )
D 13 , D 16 based on F 1 D 17 : S j | ( t s , b . s k j . α d )
D 17 based on F 4 D 18 : S j | H ( t s , b . s k j . α d ) = > S j | S K = G 2
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Share and Cite

MDPI and ACS Style

Lansky, J.; Rahmani, A.M.; Ali, S.; Bagheri, N.; Safkhani, M.; Hassan Ahmed, O.; Hosseinzadeh, M. BCmECC: A Lightweight Blockchain-Based Authentication and Key Agreement Protocol for Internet of Things. Mathematics 2021, 9, 3241. https://doi.org/10.3390/math9243241

AMA Style

Lansky J, Rahmani AM, Ali S, Bagheri N, Safkhani M, Hassan Ahmed O, Hosseinzadeh M. BCmECC: A Lightweight Blockchain-Based Authentication and Key Agreement Protocol for Internet of Things. Mathematics. 2021; 9(24):3241. https://doi.org/10.3390/math9243241

Chicago/Turabian Style

Lansky, Jan, Amir Masoud Rahmani, Saqib Ali, Nasour Bagheri, Masoumeh Safkhani, Omed Hassan Ahmed, and Mehdi Hosseinzadeh. 2021. "BCmECC: A Lightweight Blockchain-Based Authentication and Key Agreement Protocol for Internet of Things" Mathematics 9, no. 24: 3241. https://doi.org/10.3390/math9243241

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop