## 4 Healthcare AI Vulnerability Assessment Algorithm (Hava)  
Algorithm 1, the Hava, provided a structured framework for evaluating the robustness of the DL model against the abovementioned cybersecurity attacks. The Hava not only simulated and evaluated multiple attack types but also introduced the PAVI to quantify the severity of the performance degradation. The PAVI could assist in seeking actionable insights to help with defense prioritization. The high-level workflow of the Hava is shown in Figure 1.  
The process began with data preprocessing, where we normalized the input data to ensure consistent scaling across features. We carefully split the data into training and testing subsets to maintain class distribution. The DL model was trained on the preprocessed data, and its baseline performance was evaluated using accuracy and a confusion matrix. We stratified the dataset during the train-test split to maintain balanced class distributions between the training and testing subsets, and we carefully evaluated the model's performance on a separate test set, ensuring no data leakage occurred between the training and testing phases to minimize overfitting. The algorithm then systematically launched all the attacks to assess the model's resilience. The Hava computed each attack's resulting accuracy, as well as the PAVI and confusion matrix, to capture the performance impact. A key feature of the Hava is the introduction of the PAVI, which quantifies the relative drop in accuracy under each attack scenario as a percentage of the baseline accuracy. This metric provides a clear and quantitative measure of the model's attack vulnerability. The algorithm outputs the computed accuracy, PAVI and confusion matrices for all scenarios, which provides a comprehensive view of the model's vulnerabilities by considering the baseline and post-attack accuracy degradation. This systematic approach allowed for a detailed analysis of the DL model's robustness to highlight areas that required improve ments to mitigate cybersecurity risks effectively. Unlike traditional metrics, which measure accuracy, the PAVI provides a nuanced understanding of a model's vulnerabilities by evaluating the relative severity of performance degradation after an attack. It does not predict vulnerabilities beforehand but serves as a critical tool for assessing the post-attack impact and guiding future defensive strategies. By identifying and quantifying vulnerabilities through the PAVI, the HAVA enables researchers to design targeted defense mechanisms, such as adversarial training or data augmentation tailored to specific attack scenarios. **Input:**\(D\): Dataset; \(e\): Perturbation magnitude for adversarial FGSM/evasion attacks; \(\alpha\): Poisoning fraction; \(M\): Model architecture (Multi-Layer Perceptron)  
**Output:** Accuracy (\(Acc\)), Post-Attack Vulnerability Index (\(PAVI\)), Confusion Matrix (\(CM\))  
**Process:**  
1. **Data Preprocessing** 1. [label=()]
2. Normalize \(D\) using StandardScaler to scale all features to the range \([0,1]\). 2. Split \(D\) into training \((D_{train})\) and testing \((D_{test})\) subsets using stratified sampling to preserve class distribution. 3. **Baseline Model Training and Evaluation** 1. [label=()]
4. Train the model \(M\) on \(D_{train}\) using a binary cross-entropy loss function. 2. Evaluate \(M\) on \(D_{test}\) to compute baseline accuracy \(Acc_{original}\) and confusion matrix \(CM_{original}\). 5. **Attack Simulations and Evaluations** 1. [label=()]
6. **Adversarial FGSM Attack** * Generate adversarial samples \(D_{adv}\) using the FGSM: \[D_{adv}=D_{test}+\epsilon\cdot\text{sign}(\
abla_{x}J(D_{test},y)),\] where \(J\) is the loss function and \(\
abla_{x}J\) represents its gradient with respect to the input. * Evaluate \(M\) on \(D_{adv}\) to compute accuracy \(Acc_{adv}\) and confusion matrix \(CM_{adv}\). 2. **Data Poisoning Attack** * Inject mislabeled samples \((\alpha\cdot D_{train})\) into \(D_{train}\) to create \(D_{poison}\).