Over the past decade, distributed hash table- (DHT-) based routing protocols have been adopted in wireless ad hoc networks (WANETs) to achieve scalability in the route discovery phase by avoiding the flooding mechanism. The security aspects of the routing protocols based on the DHT mechanism are crucial to address and have not been discussed in the existing literature. Therefore, addressing the security issues in DHT-based routing protocols would prevent the service disruption, decrease the traffic overhead, and reduce the packet loss in the network. In this paper, several security issues are identified and elaborated through an example scenario. Moreover, a novel DHT-based routing protocol is proposed that uses a digital signature and the user’s trust in order to swap securely the logical identifiers (LIDs). Trust between nodes is established by the user’s acquaintance and the first visual contact. The proposed protocol vindicates its effectiveness via simulation results in terms of computation time, normalized overhead, percent improvement, and packet delivery ratio.