# A Privacy-Preserving Routing Protocol Using Mix Networks in Opportunistic Networks
## 3 Anonymous Routing Using a Mix Network
### Choosing Mix Nodes  
As described before, the localization of mix nodes in the network is an important issue. In order to evaluate our opportunistic mixnet proposal, we chose a set of network nodes \(\mathcal{M}\) that could act as mix  
Figure 1: Example of opportunistic mixnet.  
nodes. The size of \(\mathcal{M}\), denoted as \(|\mathcal{M}|\), or more precisely its size with respect to \(|V|\), determines the overall performance of the mixnet. Apart from its size, another important decision is how to choose such a set \(\mathcal{M}\). There are existing routing strategies in free route mixnets to optimize the anonymity of the system [13]. These strategies, however, assume that all nodes are reachable, and that routing does not opportunistically occur. In order to evaluate the use of our proposal, we provide two selection strategies focused on the performance of the opportunistic mixnet.  
The two different strategies that can be used to select set \(\mathcal{M}\) are:  
* Random selection: \(\mathcal{M}\) is randomly selected among all nodes \(V\). This is a relatively simple idea where nodes acting as mixes can be any node from the network. No other characteristic is considered.
* Centrality-based selection: \(\mathcal{M}\) is selected as the \(|\mathcal{M}|\) nodes from \(V\) with higher centrality. Here, the idea is to promote the use of highly connected nodes to act as mixes. This should improve the performance of the overall network. In order to simulate this idea, we look at nodes with higher centrality. As the centrality measure, we used the historic number of neighbors of each node. That is, a node with more contacts over time has higher centrality. In our case, we used a connection-based centrality measure that captured how many connections or interactions have a given node. More precisely, the centrality of a node \(v\in V\) is denoted as \(C(v)=|N^{*}(v)|\). In real situations, this could be equivalent to selection nodes that we know that have higher centrality or connectivity, e.g., in some vehicular networks, road-side units are known by every member of the network, and they are also central nodes. Intuitively, the centrality-based strategy yields better delivery ratios and delivery time. Those nodes have better connectivity, and messages are more efficiently routed among them. The size of set \(\mathcal{M}\) with respect to \(V\) also has performance and privacy implications, but such implications might not be that obvious. For instance, a big set of potential mix nodes imply:
* Increased privacy: as more nodes can be used as mix nodes, the attacker needs to monitor more nodes attempting to correlate inputs with outputs. This introduces confusion as a means of privacy. Privacy is actually determined by the number of messages that each mix node accepts and the number of mix nodes each message uses. The fact that there are more mix nodes present in the network hinders the task of the attacker in monitoring such nodes, and can provide better privacy due to the distribution of links in the entire mix network [13].
* More time delays: as there are more mix nodes that can be used, filling each node with its corresponding \(k_{i}\) messages takes more time, and the delay introduced by each mix node is expected to be higher. This obviously depends on the actual traffic of the network (number of messages exchanged over time), but in general, more mix nodes produce higher delay times.