# Secure D2D Communication for 5G IoT Network Based on Lightweight Cryptography
## 1 Introduction  
D2D communication is a peer-to-peer communication mechanism between devices without an intermediate node [1, 2]. D2D communication has many advantages in mobile networks [3]. First, it can expand coverage of each cell in a cellular network as a communication bridge for transmitting data to the node located outside of cell coverage. Second, D2D communication helps to reduce the energy consumption of the base station by transmitting data directly between devices. Lastly, the efficiency of reusing the same radio frequency is increased. In D2D communication, the distance between devices is quite shorter than the distance between a device and a base station. This means the interference of radio frequency decrease in D2D communication scenario, and it helps to transmit the multiple data using the same radio frequency. Moreover, D2D communication is a core technology of V2X communication [4]. Due to these advantages, the 5G network also includes D2D communication technology such as the LTE-advanced (4G) network. However, typical D2D communication in a mobile network has some security challenges [5]. The D2D communication mechanism consists of three procedures, device discovery, link setup and data transmission [6]. In this process, there is no authentication process for validating device identity. When a device sends a request for a setup link to transmit data, another node replies by sending an acknowledgement message. Moreover, D2D communication does not use encryption for confidentiality and message authentication for integrity in the communication process. This means the attacker can conduct attacks such as impersonation, eavesdropping, privacy sniffing, free-riding and location spoofing. Besides, IoT technology is combined with the 5G network to address their service demands [7], and it corresponds to mMTC and URLLC, which are the use-cases of the 5G network [5]. However, IoT applications deal with many sensitive data, and IoT devices have limited resources [8] in terms of performance, memory and power consumption. These features of IoT make the aforementioned security challenges more critical and harder to address because typical security solutions cannot be implemented or processed properly. To overcome the security challenges of D2D communication in the 5G IoT network, we need a secure D2D communication system that contains a proper authentication process between devices. Moreover, considering the resource-constrained environment, it has to be made light. Lightweight cryptography can be a proper solution for covering resource-constrained devices. Elliptic curve cryptography (ECC), which is most representative of lightweight asymmetric-key algorithms, can provide 128-bit cryptographic security using a 256-bit key, which is significantly smaller than the 3072-bit key of the most widely used public-key encryption algorithm RSA [9]. ECC has been applied to various cryptographic algorithms including elliptic curve Diffie-Hellman(ECDH) and the elliptic curve digital signature algorithm (ECDSA). ECDH and ECDSA are both cryptographic public-key algorithms but they have different purposes: ECDH is used for key exchange and ECDSA is a variation of the digital signature algorithm. ECDH is a variation of the Diffie-Hellman algorithm for elliptic curves, which is a cryptographic key agreement protocol that allows two parties with public/private key pairs on elliptic curves to obtain a shared secret key using an unprotected communication channel. ECDSA is a public key algorithm for creating a digital signature, similar in structure to a DSA, but defined, in contrast to it, not above the ring of integers, but in a group of points of an elliptic curve. In the case of the symmetric-key algorithms, many lightweight AEAD ciphers have been proposed recently to deal with a resource-constrained environment; moreover, the standardization project at the National Institute of Standards and Technology (NIST) is in process [10].