## 4 The Proposed Method: SLP-E
### Protocol Execution Phase
#### 4.2.2 Scenario-2  
The routing in scenario-2 is similar to the one suggested for scenario-1 with the following differences: (i) in phase-1, the intermediate node is randomly chosen between \(R/2\ \times\ r_{s}\) and the network boundary (measured in hops), and (ii) in phase-3, the hop count value is randomly selected between 4 hops from the VS and \(2R/3\ \times\ r_{s}\) in the inward direction, where \(r_{s}\) is the sensor node radio range. If the source node is found at the network boundary, then, there is no backward direction; only four phases are to be followed. Due to traffic diversification and energy savings, this aids in enhancing not only the network lifespan metrics but also the safety period, as all nodes in the network participate in routing the packets to the BS in different rounds. This study ensures that all nodes in the network engage in sending the packets to the BS in the different rounds in order to improve NLT, unlike existing solutions where fixed rings are utilized to make the routing diverse or to make shortest path routing route the packets to the BS. The SLP-E proposal is presented in Algorithm 1. Figure 2 summarizes the proposed protocol execution phase and shows how it enhances privacy. Only the upper limits for selecting the intermediate node (IN), virtual source (VS), and IN1 and IN2 in each phase of the two scenarios are shown in the figure. It can be noticed that in both cases, there is no chance for a packet to travel through or close to the source node (SN)'s sensing range on its way to the base station. This is because the direction in which IN2 in phase-4 is picked is the same as the direction in which VS was chosen in phase-2, and that only 90\({}^{\circ}\) distance is taken into account as the upper limit in phase-4, preventing a packet from traveling a full circle distance since 180\({}^{\circ}\) distance is taken into account in phase-2. Phase-1 scenario-1's upper limit is set at \(2R/3 rs\) to prohibit packets from reaching the network boundary once the SN is situated nearby the BS. No matter where the source node is located in the network (close to or distant from the BS), we establish the various restrictions in each phase to balance the hops a packet may traverse on its way to the BS. This helps achieve uniform privacy, prevents unnecessary delays, and reduces energy use. The adoption of multiple phases and the setting of lower and upper limitations are conducted in order to increase the randomness of the routing path and try to use every sensor node in the network to send packets to the BS; this balances energy consumption of all the sensor nodes in the network and aids in improving the NLT. ```
1 if(DetectedAsset)then
2\(/\)Obtain Network's radius in hop count terms \(radius\gets NetworkRadius()\);
3//Define Hop Threshold \(h_{t}\gets int(round(radius/4,0))\);
4\(/\)Get Hop Count of the Source Node \(sn\_{hc}\gets HopCountSN()\);
5//Choose the group of Source Node if\(sn\_{hc}\)\(<=\)\(h\_{t}\)then
6\(group=1\);
7 else
8\(group=2\);
9\(/\)Backward Random Walk (BRW) //Select only the Far-away Neighbor Set \(onlyFurtherSet\gets True\);
10\(/\)Based on the selected group, decide the no. of hops if\(group_{c}==1\)then
11\(h_{1}\gets random(radius/3,(2\times radius)/3)\);
12 else
13\(h_{1}\gets random(radius/2,radius)\);
14 for\(i=1\):\(h_{1}\)do
15\(/\)Select the neighbor for relaying \(NodeRelay\gets GetBackwardListNode(onlyFurtherSet)\);
16\(TransferPacket(NodeToRelay)\);
17\(PresentNode\gets NodeToRelay\);
18\(/\)Clockwise Walk and Anti-Clockwise Walk //Select the Traveling Direction \(walkDirection\gets random(0,1)\);
19\(/\)Select the no.