## 4 A Case Scenario in Smart Healthcare CPS  
A hypothetical scenario is described below to illustrate how the proposed framework prevents malicious actors from exploiting vulnerabilities in a smart healthcare CPS. Preventing Unauthorized Access to Patient Records1. Trust parameter collection: Child nodes within the device layer, such as wearable health trackers and medical sensors, continuously collect trust parameters. These parameters include the packet loss ratio, energy consumption, end-to-end delay, and packet forwarding behavior. 2. Forwarding to fog layer: The collected trust parameters are forwarded to the fog layer through a designated sink or root node. The root nodes forward all received trust parameters to the fog servers for processing and analysis at the fog layer. 3. Device registration: The fog servers register the device if it is not already included in the device-acquire function and allow the requesting device to become part of the smart healthcare CPS. 4. Gini index calculation: Utilizing the Gini index, the fog layer assesses the distribution of trust parameters across the smart healthcare CPS. Anomalies, such as unexpected spikes in device activity, trigger alerts. 5. Trust updating and blockchain integration: Based on the Gini index analysis, the trust values of nodes are updated in the BRGTL. The updated trust values, along with the trust parameters, are stored in the BRGTL smart contract in the blockchain. 6. Maintaining BRGTL on blockchain: The BRGTL smart contract securely maintains an immutable record of the updated trust values and is accessible to all fog servers. It provides a historical reference for trust assessments and ensures tamper-resistant record keeping. 7. Communication with device layer: The fog layer communicates with the device layer, specifically sharing the updated trust values stored in the BRGTL smart contract. This communication enables devices to be informed of changes in trust assessments. \begin{table}
\begin{tabular}{l l l} \hline \hline
**Model Type** & **Advantages** & **Disadvantages** \\ \hline \multirow{4}{*}{Fully Decentralized [85]} & Resilience: More resilient against & Complexity: Complex to \\  & SPOF. Security: Improved & implement and manage. \\  & security due to the absence of a & Scalability challenges: \\  & central authority. & Challenges, especially in \\  & & large-scale smart healthcare CPS. \\ \hline \multirow{4}{*}{Fog Computing [86]} & Reduced latency: Reduces & Consistency challenges: Ensuring \\  & latency and improves real-time & consistent trust assessments \\  & decision making. Enhanced & across edge devices may require \\  & privacy: Reduces the need to & additional coordination \\  & transmit sensitive information & mechanisms. \\  & across the network. & \\ \hline \multirow{4}{*}{Cloud-Based [87]} & Scalability: Allows for scalability & Dependency on cloud service \\  & by leveraging cloud resources. & providers (CSP): Reliance on \\  & Resource management: Can & external CSPs introduces a \\  & better manage computational & dependency. Security concerns: \\  & resources. & Security concerns due to the \\ \hline \multirow{4}{*}{Mesh Network [88]} & Redundancy: Provides & Complex routing: Challenges in \\  & redundancy and resilience. & ensuring timely and efficient \\  & Adaptability: Well-suited for & communication for trust \\  & dynamic healthcare & parameter exchange. Resource \\  & environments. & consumption: Consumes more \\  & environments. & energy and resources compared \\  & to other models. & \\ \hline \hline \end{tabular}
\end{table} 
Table 5: _Cont._Preventing unauthorized access: Suppose a malicious actor attempts to gain unauthorized access to patient records by exploiting vulnerabilities in a compromised device. The real-time trust assessment, Gini index analysis, and BRGTL record keeping collectively identify this anomalous behavior and isolate the malicious attacker node.