# Research on Secure Community Opportunity Network Based on Trust Model
## 2 Related Works  
The inception of opportunistic networks can be traced back to early delay-tolerant networks [20], first conceptualized at EXOR in 2005 [21]. Presently, both domestic and international academic research endeavors pertaining to opportunistic networks primarily delve into their social characteristics [22]. The proposed algorithm significantly enhances the data transmission performance within opportunistic networks. Subsequently, the following section will delve into various existing opportunistic routing algorithmsIn opportunistic networks, routing algorithms are commonly categorized into non-context-aware and context-aware routing algorithms [23]. Non-context-aware routing algorithms often resort to flooding for data transmission, resulting in the proliferation of redundant message copies within the network, consequently leading to elevated message forwarding delays and increased energy consumption [24]. The Epidemic [25] algorithm stands as a classic non-context-aware routing algorithm, modeled after the spread of infectious diseases. Although effective in reducing network transmission delay under optimal resource conditions, the Epidemic algorithm struggles to deliver favorable outcomes in natural environments due to network congestion with increasing node density. To address the limitations of the Epidemic algorithm, the Spray and Wait algorithm was introduced, fixing the number of message copies N at the outset [26]. This algorithm comprises two stages: the spray stage, where the source node broadcasts N copies of the message, and the wait stage, where nodes carrying message copies wait in the network. However, the challenge lies in setting the optimal number of message copies, as too few copies may hinder message delivery, while an excessive number may exacerbate forwarding delays and energy consumption. Context-aware routing algorithms select the next-hop relay node based on user contextual information, such as geographical location, historical data, and social relationships [27]. Nonetheless, these algorithms often necessitate extensive information and intricate computations, contributing to additional transmission delays and energy consumption. In BubbleRap [28], nodes are segregated into different communities, with preference given to nodes within the same community as the destination node when selecting the next-hop relay node. However, over time, this algorithm may witness the formation of large, encompassing communities, diminishing the significance of community division. Furthermore, prioritizing nodes with high centrality for data forwarding may lead to node congestion and rapid energy depletion. [PERSON] et al. [29] proposed the Edge Collaborative Cache Trust Community (ECTC) routing algorithm, which employs comprehensive trust indicators to partition trust communities. This algorithm utilizes explicit labels for direct trust and calculates node similarities through inter-node paths for indirect trust. Trusted relay nodes assist in cache cooperative transmission by trusting neighbor nodes (edge nodes) with surplus cache space within the community. Simulation experiments validate the efficacy of the Edge Collaborative Cache Trust Community (ECTC) routing algorithm in improving message transmission success rates and reducing network overhead. Table 1 provides a comprehensive analysis of existing relevant research. Building upon the exploration of the aforementioned methodologies, this paper introduces a more effective approach to achieve secure and efficient data transmission within opportunistic networks. \begin{table}
\begin{tabular}{l l l l l} \hline \hline \multicolumn{1}{c}{**Classification**} & \multicolumn{2}{c}{**Non-Context-Aware Routing Algorithms**} & \multicolumn{2}{c}{**Context-Aware Routing Algorithms**} \\ \hline \multirow{3}{*}{**Algorithm**} & Epidemic & **Spray and Wait** & **BubbleRap** & **ECTC** \\ \hline \multirow{3}{*}{**Strategy**} & Employing the data flooding & Message-spared approach on & The security community is \\  & forwarding errors, & the number of copies.