The significant advancement of blockchain technology in the field of industrial networks has created a meaningful impact and for this, it comes to the field of the military where blockchain can have a
greater impact. In the military environment, a lot of machines and smart devices are connected. Unmanned aerial vehicle (UAV) combined with mobile edge computing (MEC) can offer real-time services. However, through the UAV, smart devices and intelligent machines, attackers can easily access. This leads to disruption on operations and revealing the data confidentiality to an adversary. To prevent this issue an architecture is proposed based on blockchain technology. The architecture is applied to provide a solution for malicious cyber-attacks and prevent data loss to ensure the security on device-to-device (D2D) communication in the military network to provide maximum security. Simulation results illustrate that how efficaciously the applied method can work for restorative the security on D2D communication. Finally, in conclusion, how the proposed framework can be enhanced by applying other feasible techniques along with future research directions is discussed.