# Tokens Shuffling Approach for Privacy, Security, and Reliability in IoHT under a Pandemic
## 3 Proposed Approach (TSA)
### Algorithm of TSA
* The performance will be adversely affected by the increase in the level of specificity associated with SO, and since SOq > Sq, S will inevitably increase and will affect the transmission time and the total processing time T. \[\text{T\_Dbfuscation = Tsp*Nq*SOq + Tprocess*Nq*SOq}\] (8)* It also affects the accuracy of the results because of its effect on Sq and increases the noise on the data sent to the service provider. * It is not effective with the cache, as the hit rate in the cache will be lower due to the obfuscation of the real user's location within a random area that is difficult to replicate. * It does not require trusting a third party, including Peer, Fog, or SP. * It does not protect data security but only its privacy. #### 4.2.3 Peer Cooperation Approach--Results

* The level of protection in the traditional approach to cooperation is related to the number of peers collaborating, and the value of E increases with the number of peers, but it will not reach the value of Max (E). In the case of the developed SPF approach, it uses the exchange method between users, and, therefore, each user sends someone else's query, and then it will be E = 1 because the service provider will not have any real information about the user. * The level of performance is also related to the number of cooperative peers, as it affects the size of the collecting area for them and the number of their different queries, meaning that both Sq and Nq will be affected by the increase, and this will affect T adversely with the increase as well. However, in the developed SPF, the situation will become better due to the cooperation with one peer and therefore the value of T.

\[\text{T\_Cooperation}\ =\ \text{Tsp}*\text{Nq}\ +\ \text{Tprocess}*\text{Nq}\ +\ \text{Tpeer}*\text{Nq} \tag{9}\]
* In systems that depend on non-correlated static queries, the SPF approach will not affect the accuracy of the queries. Still, in the case of dynamic queries requiring the service provider to collect all user queries in a certain period (such as medical systems), it adversely affects the accuracy of the results of this process. * It is effective with the cache because only actual queries are stored in the cache. * It requires the user to trust the peer and does not require the user to trust the fog or SP. * It is concerned with protecting privacy, not security. #### 4.2.4 Blind Third-Party Approach--Results

* It provides a maximum protection level of E = 1 because the user does not communicate with the service provider directly but rather through the fog node. It hides the information from the fog node through encryption with the service provider's public key. * The performance will adversely affect the processing time of each query, as encoding and decoding time will be added at each Tenc_dec end, as well as an increase in transmission time to the fog node as an extra step. There is also a slight increase in query size due to the addition of a session key in each query to encrypt the returned results. \[\text{T\_BTP}\ =\ \text{Tsp}*\text{Nq}+\ \text{Tprocess}*\text{Nq}*\text{Tenc\_dec} \ +\ \text{Tfog}*\text{Nq} \tag{10}\]
* It will not affect the accuracy of the queries. * It is considered unsuitable for the cache in its basic form because the fog node cannot read the encrypted data. * It does not require trust in the peer, fog, or SP, but the fog node may cooperate with the SP to breach privacy, and the fog node, in case it is malicious, can send a fake query to tamper with the accuracy of the data of the service provider. * It provides data security and privacy. #### 4.2.5 TSA--Results

* It provides a maximum level of protection E = 1 because the user does not send his data to the service provider himself but rather through another user. It hides information from the cooperating user through encryption. * The performance level will be greatly improved. Although encryption is used with more time to deal with the fog node and then the peer, this only happens once (N = 1) for an aggregated set of queries or data when there is a need to share it.