Abstract:This paper proposes a secure routing algorithm based on game theory to optimize routing strategies for the problem of malicious nodes that intend to spread malware in a communication system that combines device-to-device and mobile edge computing, and verifies the feasibility of the algorithm. The algorithm assumes that the nodes in the device-to-device communication system are equipped with anti-malware controls, and select the safe routes using game theory based on the detection cost, routing QoS and the joint detection capability of the malware to taking into account the security of packet transmission and the QoS. Simulation results show that the designed secure routing algorithm can take into account the security and QoS of data packet transmission.