In an ad hoc network, the routing protocol takes into account a variety of activities, including maintaining network connection, transmission scheduling, channel evaluation, and preserving network connectivity. Additionally, it determines network architecture. In addition, a number of different elements determines the performance of a routing protocol. These include node mobility, which is responsible for multiple link failures, support for quality of service (QoS), network size, the amount of traffic, and the level of security. The performance may occasionally also be affected by the manner in which the network is behaving in addition to the kinds of apps that are running in that environment. Selecting an appropriate protocol that is based on security is highly crucial in order to set up an effective network. A significant amount of effort has been put into improving the safety mechanisms that are built into routing protocols, most prominently in WSNs, MANETs, VANETs, and WMNs. Only MANET will be the topic of discussion here. Mobile Ad-Hoc Network is a wireless network that does not need infrastructure and is composed of mobile nodes. Mobile ad-hoc network, also known as MANET, is one of the most promising forms of next-generation wireless networking technology. It has garnered a significant amount of interest because it is self-organized and can be deployed at a cheap cost. In comparison to a traditional network, a MANET presents a number of challenges that are especially difficult to overcome when it comes to the duty of routing. The many difficulties that are inherent with MANET have made it an excellent subject for academic investigation. This provides a concise overview of security in MANETs as well as the issues that relate to maintaining them. Understanding the different routing mechanisms and the potential attacks that might be mounted against them is the first step in designing a reliable security mechanism. Within the scope of this study effort, we have provided specifics on the detection and prevention of various routing attacks, with the primary emphasis being placed on the network layer assaults that are unique to MANET. When compared to other study fields, MANET presents the greatest challenge in terms of maintaining network security. In recent years, a significant amount of research has been carried out to investigate several forms of assault; nevertheless, most of the surveys have been carried out without any kind of performance analysis. There is a paucity of research that seeks to find an all-encompassing study of the impact of the many different attacks that bring the overall performance of the Adhoc network down. On the other hand, secure routing in the face of a black hole attack can be difficult because preferences are often incomplete. The in-degree centrality and importance degree measurement applied to the collected consensus-based trust from decision-makers solves the issue of incomplete preferences and improves the accuracy of trust at the same time. Utilizing Network Simulator, we examine how well the suggested approach works. Based on the findings of the simulations, it has been demonstrated that the detection accuracy and throughput of the proposed CREDIT are both significantly higher than those of existing work, making the proposed CREDIT scheme superior.