This study used a fully synthetic healthcare dataset generated for experimental evaluation of secure cloud data migration. No real patient data, protected health information (PHI), or identifiable healthcare records were used. Therefore, Institutional Review Board approval and informed consent were not required. All the materials used in this study are included in the Table of Materials.
1. Overview
- Configure a secure cloud migration environment consisting of a source layer, migration hub layer, target layer, network layer, identity and access management layer, observability layer, and explainable AI layer.
- Deploy all components within isolated cloud environments to support secure healthcare data migration. Establish encrypted communication channels between all system components.
- Execute the protocol through dataset preparation, environment configuration, architecture deployment, secure migration, anomaly monitoring, and post-migration validation. The overall architecture of the proposed Explainable AI-driven secure cloud data migration framework is illustrated in Figure 1.

Figure 1: Overall architecture of the explainable artificial intelligence (XAI)-enabled secure cloud data migration framework for healthcare systems. The framework consists of the identity and access management layer, source database layer, migration hub layer, target cloud database layer, network security layer, observability layer, explainable AI monitoring layer, and cross-cutting security and governance services. The architecture integrates temporal least-privilege access control, TLS 1.3 encrypted communication, checksum-based integrity verification, continuous security monitoring, and SHAP-based explainability to provide secure, transparent, and reproducible healthcare database migration. This figure was created by the authors using Microsoft PowerPoint (Microsoft 365). Please click here to view a larger version of this figure.
2. Computational environment configuration
- Configure the computational environment
- Prepare the computational resources required for secure cloud data migration and explainable AI-based monitoring.
- Install and configure all hardware, software, cloud services, databases, security tools, and machine learning libraries listed in the Table of Materials. Verify that all required components are operational before initiating the migration experiment.
- Configure the Cloud Environment
- Set up a cloud environment that is secure for healthcare data migration. Set up a private VPC for seamless communication between the source, migration hub, and target systems. Use strong encryption not only when data is stored, but also when it is transmitted.
- Prepare the target database and migration services according to the details mentioned in the Table of Materials.
- Configure identity and access management. configure monitoring and logging services.
3. Dataset preparation and description
- Generate a synthetic healthcare dataset using the Faker Python library listed in the Table of Materials. Configure demographic attributes, including patient age, sex, ethnicity, and geographic location, using predefined probability distributions.
- Generate clinical information, including diagnoses, laboratory results, medications, allergies, procedures, and hospital admissions, while preserving realistic clinical relationships.
- Generate longitudinal patient encounters by assigning multiple visits to individual patients according to predefined visit-frequency distributions.
- Generate timestamps for admissions, laboratory investigations, medication administration, discharge summaries, and audit logs using chronological event ordering.
- Introduce clinically realistic missing values, duplicate records, and outlier observations according to predefined data-quality distributions.
- Replace all personally identifiable information with synthetic values generated using the Faker library. Validate referential integrity and logical consistency before exporting the dataset. Export the validated dataset in PostgreSQL-compatible SQL format. Configure the dataset to support realistic healthcare migration scenarios. The characteristics of the generated dataset are summarized in Table 1.
- Define database relationships. Assign Patient_ID as the primary key for the patient table. Establish foreign-key relationships between patient, visit, laboratory, medication, and audit-log tables. Verify referential integrity across all tables before initiating migration.
- Simulate realistic healthcare data characteristics. Generate patient ages using a normal distribution. Generate visit frequencies using a Poisson distribution. Introduce missing values at a rate of 5% to simulate real-world EHR incompleteness. Replace all patient identifiers with hashed values before migration. Verify that all generated records conform to predefined schema constraints.
- Validate the generated dataset by checking schema consistency, referential integrity, missing values, duplicate records, and predefined quality constraints before migration.
| Parameter | Value |
| Dataset Type | Synthetic Healthcare EHR Dataset |
| Dataset Size | 10 GB |
| Total Records | 20 Million |
| Number of Tables | 5 Core Tables- 28 relational tables |
| Patient Records | 5,000,000 |
| Visit Records | 10,000,000 |
| Laboratory Results | 4,000,000 |
| Medication Records | 3,000,000 |
| Audit Logs | 5,000,000 |
| Primary Key | Patient_ID |
| Missing Value Rate | 5% |
| Age Distribution | Normal Distribution |
| Visit Frequency | Poisson Distribution |
| Integrity Threshold | <0.1% Violations |
Table 1: Characteristics of the synthetic healthcare dataset used for protocol validation. The table provides an overview of the dataset, such as database size, number of relational tables, total records, patient attributes, clinical variables, and validation characteristics to reproduce the secure migration experiments.
4. System architecture deployment
- Deploy the secure cloud migration architecture consisting of the source layer, migration hub layer, target layer, network security layer, observability layer, and explainable AI layer. The deployed system architecture used in this study is illustrated in Figure 2.
- The framework is composed of six working layers, which, during the migration process, carry out their functions one after another. The first layer, the Source Layer, is the one that contains the synthetic healthcare database.
- The Migration Hub is the one in charge of schema extraction, encrypted data transfer, integrity validation, and migration orchestration. The target layer is where the migrated database is stored in Amazon RDS PostgreSQL.
- The network security layer is the one that safeguards all the communications by the use of private VPC endpoints, TLS 1.3 encryption, security groups, and network access control lists.
- The observability layer is the one that is always collecting authentication logs, migration logs, database activity logs, and security events with the help of Amazon CloudWatch.
- The explainable AI layer is the one that gets the security telemetry that has been collected, runs it through an Isolation Forest algorithm, and produces SHAP-based explanations for the anomalies that have been found. All architectural layers communicate with one another via private network channels that are authenticated during the entire migration workflow.
- Deploy and verify the source database environment to ensure secure access and data availability before migration.
- Set up a PostgreSQL 16 database with the synthetic healthcare dataset. Keep patient information, visit details, lab results, drug records, and audit logs in the source database.
- Restrict database access to authorized migration services and administrative users only. Verify database availability and connectivity before initiating migration operations.
- Configure the migration hub to coordinate schema extraction, encrypted data transfer, and migration orchestration.
- Deploy a dedicated migration server within the private Virtual Private Cloud (VPC). Configure migration orchestration services to coordinate schema extraction, data transfer, and validation activities.
- Enable schema-validation services to verify compatibility between source and target environments. Enable integrity-verification services to validate migrated data during and after transfer. Verify communication between the migration hub and database systems before executing migration tasks.
- Deploy the Target Layer. Deploy Amazon RDS PostgreSQL 16 as the target database environment. Enable automatic backup and recovery services. Enable AES-256 encryption for data stored within the target database.
- Configure Network Security. Disable all public IP addresses associated with migration resources. Permit communication only through private endpoints within the VPC. Configure network access control lists (NACLs) and security groups. Enable TLS 1.3 encryption for all communications between system components. Verify that no publicly accessible endpoints remain active.
- Configure centralized monitoring to continuously collect security events, migration logs, and system performance metrics.
- Enable Amazon CloudWatch logging and monitoring services. Collect authentication logs, migration logs, database activity logs, and security-event logs. Configure log retention for 365 days. Enable immutable log storage to support auditing and compliance requirements. Verify real-time metric collection and alert generation.
- Configure the explainable AI environment to perform real-time anomaly detection and generate interpretable security explanations.
- Deploy anomaly-detection services within the monitoring environment. Configure the Explainable AI framework to process security telemetry generated during migration. Connect security telemetry streams from the source, the migration hub, the target database, and the monitoring services.
- Enable real-time anomaly detection and SHAP-based explanation generation. Verify successful ingestion of telemetry data before initiating migration experiments.

Figure 2: Deployment architecture of the secure healthcare cloud migration framework. The deployment environment illustrates the source PostgreSQL database containing the synthetic healthcare dataset, the dedicated migration hub within a private virtual private cloud (VPC), the Amazon RDS PostgreSQL target database, the network security layer, centralized observability through Amazon CloudWatch, and the Explainable Artificial Intelligence monitoring layer. All communication occurs through private endpoints protected by TLS 1.3 encryption. This figure was created by the authors using Microsoft PowerPoint (Microsoft 365). Please click here to view a larger version of this figure.
5. Secure migration workflow
NOTE: Execute the secure migration workflow by performing threat modeling, schema transfer, secure data migration, migration validation, and post-migration hardening.
- Identify potential security threats and map appropriate mitigation controls before initiating the migration process.
- Identify migration assets, potential attack vectors, and realistic cyberattack scenarios.
- Evaluate credential theft resulting from compromised authentication tokens, insider attacks involving unauthorized administrative access, replay attacks targeting previously intercepted authentication requests, man-in-the-middle (MITM) attacks attempting to intercept encrypted communication channels, schema tampering intended to modify database structures during migration, and privilege-escalation attacks aimed at obtaining unauthorized administrative permissions.
- Check that using temporal least-privilege credential management is sufficient in preventing credential theft and privilege-escalation attacks. Verify that communication encrypted with TLS 1.3 protects from replay attacks and man-in-the-middle attacks.
- Verify identity and access management (IAM) policies prevent unauthorized administrative access. Verify continuous audit logging keeps a record of all security-related migration activities. Make sure that checking by SHA-256 checksum is able to detect unauthorized changes to schema or data.
- Verify that the explainable anomaly detection framework can locate unusual migration activities and can also provide interpretable security explanations. Make a security control map for each threat that has been identified. Verify that all identified threats are adequately mitigated before you start migrating the database. The authors summarized the threat model and security controls in Table 2.
- Transfer Database Schema. Extract schema definitions from the source PostgreSQL database. Validate schema compatibility with the target database environment. Verify table structures, primary keys, foreign keys, indexes, and constraints. Deploy validated schema definitions to the target database. Confirm successful schema deployment before transferring data.
- Migrate healthcare data securely through encrypted communication channels while continuously monitoring migration activities.
- Configure the migration batch size to 10,000 records per transaction. Establish encrypted communication channels using TLS 1.3. Transfer data through private network endpoints within the virtual private cloud (VPC).
- Enable automatic retry attempts with a maximum of three retries for failed transactions.
Maintain data-transfer throughput between 100 MB/s and 150 MB/s. Monitor migration activities continuously throughout the transfer process. Record all migration events in centralized audit logs.
- Verify migration completeness and integrity by comparing checksums, record counts, and database structures.
- Generate SHA-256 hash values for all source tables before the migration, and SHA-256 hash values for all target tables after the migration. Match source and target checksum values. Cross-check row counts for source and target databases. Check consistency of schemas, table relationships, and database constraints. Consider migration as successful only when checksum values, record counts, and schema structures are identical.
- Remove temporary privileges and finalize security controls after successful completion of data migration.
- Revoke all temporary migration credentials immediately after migration completion. Remove elevated migration privileges from service accounts. Archive audit logs and security monitoring records.
- Verify successful completion of backup procedures. Decommission temporary migration servers and supporting resources. Perform a final security review of the migrated environment. Document migration outcomes and validation results. The complete secure migration workflow used in this study is illustrated in Figure 3.
| Threat Scenario | Security Control | Detection Method | Mitigation |
| Credential theft | Temporal Least Privilege (TLP) | IAM logs | Automatic credential revocation |
| Insider attack | Role-Based Access Control (RBAC) | Audit logs + SHAP | Session termination |
| Replay attack | TLS 1.3 + Nonce validation | Network monitoring | Reject duplicated requests |
| Man-in-the-Middle (MITM) | TLS 1.3 encryption | Certificate validation | Encrypted communication |
| Schema tampering | SHA-256 checksum + schema validation | Integrity verification | Restore validated schema |
| Privilege escalation | IAM policy enforcement | Security logs | Privilege revocation |
Table 2: Threat model and respective security measures taken in the migration framework proposed. The table outlines the main representative security threats and their corresponding mitigation mechanisms based on zero-trust security principles, encryption, identity management, integrity verification, monitoring, and explainable anomaly detection.

Figure 3: Workflow of the proposed secure cloud database migration protocol. The protocol consists of seven sequential stages: threat modeling, schema transfer, secure database migration, migrated data validation, post-migration hardening, audit logging and archival, and migration completion. Security monitoring, encrypted communication, identity management, immutable logging, and explainable anomaly detection are maintained throughout the migration workflow. This figure was created by the authors using Microsoft PowerPoint (Microsoft 365). Please click here to view a larger version of this figure.
6. Configure explainable AI monitoring
NOTE: The outline of the process is: identifying migration security characteristics, building a model to detect irregularities, recognizing when migration actions are suspicious, and producing explainable results through SHAP interpretation methods.
- Extract and preprocess security telemetry features required for anomaly detection and explainability analysis.
- Collect security logs from database servers, authentication servers, application servers, and network monitoring systems. Aggregate all migration-related events into a centralized log repository. Remove duplicate records and incomplete entries. Synchronize timestamps across all log sources using coordinated universal time (UTC).
- Calculate access frequency for each user during migration operations. Record the number of failed login attempts associated with each account. Monitor changes in source IP addresses throughout migration sessions.
- Measure user session duration from login initiation to termination. Calculate inbound and outbound data transfer volumes during migration activities. Normalize all extracted features using Min-Max normalization.
- Table 3 summarizes the security features used for anomaly detection and explainability analysis.
- Train and validate the Isolation Forest model using the prepared security feature dataset.
- Partition the dataset. Randomly divide the dataset into Training set (70%), Validation set (15%), and Testing set (15%). Maintain a consistent distribution of normal and anomalous events across all subsets.
- Explainable AI Model Selection. Select the Isolation Forest algorithm because it efficiently detects anomalous migration activities without requiring labeled training data. Use the algorithm to isolate abnormal observations through recursive random partitioning of the feature space.
- Apply SHAP TreeExplainer to quantify the contribution of each security feature to the anomaly prediction and improve transparency of the security monitoring process.
- Configure the anomaly detection model. Initialize an Isolation Forest model. Configure the model using the parameters listed in Table 4.
- Define the mathematical formulation used to calculate anomaly scores and explain feature contributions.
- Define the security feature vector for each migration event as shown in Equation 1.
xi = [x1 , x2, x3, x4, x5 ] (1)
where x1 denotes access frequency, x2 denotes failed login count, x3 denotes IP address change frequency, x4 denotes session duration, and x5 denotes data transfer volume.
- Extract the security features from migration logs. Normalize all feature values before model training. Calculate the Isolation Forest anomaly score for each migration event using Equation 2.
(2)
where S(X,n) denotes anomaly score of observation X, X denotes security feature vector, E(h(X)) is expected path length of observation X, c(n) is average path length of unsuccessful searches in a binary search tree, and n is the total number of training samples. The normalization factor is calculated as shown in Equation 3.
(3)
where H(n-1) denotes the (n-1)th harmonic number.
- Classify migration events with anomaly scores greater than the predefined decision threshold as anomalous.
- Apply SHAP (SHapley Additive exPlanations) to explain the contribution of each security feature to the anomaly prediction. Calculate the SHAP value for feature i using Equation 4.
(4)
where (F) denotes the complete feature set, (S) denotes a subset of features, and (f(.)) denotes the Isolation Forest prediction function.
- Calculate the global feature importance by computing the mean absolute SHAP value using Equation 5.
(5)
where (N) denotes the total number of migration events.
- Rank the security features according to their mean absolute SHAP values. Generate SHAP summary plots, dependence plots, and force plots to visualize global and local feature importance.
- Train the Isolation Forest model using the training dataset. Evaluate model performance using the validation dataset. If it is necessary, change the contamination thresholds. Store the model configuration that performs the best. Validate model performance. Determine metrics like accuracy, precision, recall, F1-score, and ROC-AUC. Note down the model performance measures for later comparison.
- Apply the trained model to identify abnormal migration events and classify suspicious activities.
- Perform anomaly prediction. Apply the trained Isolation Forest model to the testing dataset. Generate anomaly scores for all migration events.
- Identify suspicious activities. Determine if migration events are typical or anomalous. Mark as suspicious those events that surpass predetermined anomaly levels. Produce anomaly documentation for security scrutiny.
- Completion of the anomaly detection process yields anomaly scores, labels migration events as normal or anomalous, measures detection effectiveness through ROC analysis, and spots key security anomalies. Samples of outputs produced by the designed process are shown in Figure 4.
- Categorize detected anomalies. Classify anomalies into authentication anomalies, network anomalies, session anomalies, and data-transfer anomalies. Keep the anomaly labels for the explanation analysis.
- Evaluate detection performance. Check the recorded security incidents to date. Then, using them as a reference, evaluate the anomalies that have been detected and figure out which of the two were true anomalies. Determine the rate at which anomalies are detected and the rate of false positives. Make an official record of the documentation of detection accuracy to be able to reproduce it.
- Generate SHAP-based explanations to interpret the contribution of individual security features to anomaly predictions.
- Configure the SHAP environment. Load the trained Isolation Forest model. Initialize SHAP TreeExplainer. Verify successful integration between the anomaly detection model and the explainability framework.
- Select background samples. Randomly select 1,000 representative samples from the training dataset. Use the selected samples as the SHAP background dataset. Calculate SHAP values. Compute SHAP values for all detected anomalies. Measure individual feature contributions to anomaly predictions. Store SHAP outputs for further analysis.
- Generate global explanations. Create SHAP summary plots showing overall feature importance. Generate SHAP bar charts based on mean absolute SHAP values. Produce SHAP dependence plots for highly influential features.
- Generate local explanations. Select representative anomalous migration events. Create SHAP force plots and waterfall plots. Visualize feature contributions responsible for each anomaly.
- Representative explainability outputs generated during the interpretation process are shown in Figure 5. These visualizations demonstrate global feature importance, feature contribution rankings, dependence relationships between influential security features, and local explanations for individual migration anomalies.
- Rank security features. Calculate mean absolute SHAP values for all features. Rank features according to their contribution to anomaly detection. Identify the most influential security indicators affecting migration security. Table 5 summarizes the SHAP-based feature importance rankings.
- Validate explanation consistency. Repeat SHAP analysis across five independent experimental runs. Measure explanation stability and consistency. Verify that feature rankings remain stable across repeated analyses.
NOTE: Table 6 provides common issues encountered during explainable anomaly detection and recommended corrective actions.
| Feature | Description | Purpose |
| Access Frequency | Number of user access requests during migration | Detect abnormal access behavior |
| Failed Login Count | Number of unsuccessful authentication attempts | Identify brute-force or unauthorized access attempts |
| IP Address Changes | Frequency of source IP address changes | Detect suspicious network behavior |
| Session Duration | Length of user sessions during migration | Identify abnormal session activities |
| Data Transfer Volume | Amount of data transferred during migration | Detect unusual data movement or exfiltration |
Table 3: Security telemetry features used for explainable anomaly detection. The table presents the security features that were monitored during the database migration, their meanings, the ways in which they were measured, and how they helped with anomaly detection and explainability analysis.
| Parameter | Value | Description |
| Algorithm | Isolation Forest | Anomaly detection model |
| n_estimators | 100 | Number of isolation trees |
| contamination | 0.02 | Expected anomaly proportion |
| max_samples | Auto | Samples used per tree |
| random_state | 42 | Reproducibility seed |
| bootstrap | False | Sampling without replacement |
| Training Set | 70% | Model training data |
| Validation Set | 15% | Hyperparameter validation |
| Testing Set | 15% | Final model evaluation |
Table 4: Configuration of Isolation Forest used for detecting anomalies during secure database migration. This table details the hyperparameter setups of the Isolation Forest model for training, such as how the dataset was split, the level of contamination, the number of estimators, the random seed, and the evaluation setup.

Figure 4: Representative outputs of the anomaly detection framework during secure cloud data migration. (A) Distribution of Isolation Forest anomaly scores showing the anomaly threshold. (B) Classification of migration events into normal and anomalous categories. (C) Receiver operating characteristic (ROC) curve demonstrating the performance of the Isolation Forest model (AUC = 0.97 ± 0.01). (D) Representative anomalous migration events showing anomaly scores, predicted labels, influential security features, and anomaly categories. This figure was generated by the authors using Python 3.11 (Matplotlib 3.9) and formatted using Microsoft PowerPoint (Microsoft 365). Please click here to view a larger version of this figure.

Figure 5: Examples of SHAP-based explainability outputs produced during anomaly interpretation. (A) SHAP summary plot highlighting the most important features globally. (B) Ranking of security features based on their mean absolute SHAP value. (C) SHAP dependence plots demonstrating how the number of failed logins and the volume of data transfer affect the anomaly prediction. (D) SHAP force plot offering a local explanation for a typical abnormal migration event. These charts showcase the global and local interpretability of the proposed anomaly detection model. This figure was generated by the authors using Python 3.11 (Matplotlib 3.9) and formatted using Microsoft PowerPoint (Microsoft 365). Please click here to view a larger version of this figure.
| Rank | Feature | Mean Absolute SHAP Value | Interpretation |
| 1 | Failed Login Count | 0.352 | Most influential indicator of anomalous activity |
| 2 | Data Transfer Volume | 0.287 | Strong contributor to anomaly detection |
| 3 | IP Address Changes | 0.221 | Indicates suspicious network behavior |
| 4 | Session Duration | 0.184 | Associated with abnormal user sessions |
| 5 | Access Frequency | 0.156 | Reflects unusual access patterns |
Table 5: SHAP feature importance scores of security telemetry data. The table shows security feature ranking according to their mean absolute SHAP values and outline their respective contributions to the prediction of anomalies.
| Issue | Possible Cause | Recommended Solution |
| Few anomalies detected | Contamination parameter too low | Increase the contamination threshold and retrain the model. |
| High false-positive rate | Noisy or inconsistent migration logs | Clean log data and normalize security features before model training. |
| Unstable SHAP explanations | Insufficient background samples | Increase the number of representative background samples used by SHAP. |
| Poor anomaly detection accuracy | Feature imbalance or inadequate preprocessing | Apply feature normalization, balancing, and quality-control procedures. |
| Slow model convergence | Large dataset or limited computational resources | Optimize hyperparameters or use GPU/parallel processing. |
| Communication failures | Network instability during monitoring | Verify secure communication channels and repeat synchronization. |
| Missing security features | Incomplete log collection | Validate log sources before feature extraction and regenerate the feature dataset. |
Table 6: Guide for troubleshooting Explainable Artificial Intelligence-based secure database migration. This table provides a summary of typical implementation problems, possible reasons, diagnostic signs, recommended actions, and outcomes expected as a result of protocol execution and reproducibility.
7. Performance evaluation
NOTE: This section describes the experimental procedure used to compare the baseline migration framework with the proposed zero-trust explainable AI-based migration framework. Performance evaluation includes security, anomaly detection capability, migration efficiency, and statistical validation under identical experimental conditions.
- Configure both the baseline and proposed environments under identical conditions to enable a fair performance comparison.
- Configure the conventional migration environment. Configure long-term static credentials with a validity period greater than 24 h. Enable public network endpoints for database access. Disable AI-based anomaly detection and explainability mechanisms. Monitor migration activities manually using conventional security logs. Record migration events for subsequent performance comparison.
- Configure the Zero-Trust migration framework. Enable temporal least-privilege credentials with automatic expiration after migration completion. Disable all public network endpoints. Enable private network communication using secure channels.
- Deploy the trained Isolation Forest anomaly detection model. Enable SHAP TreeExplainer for model interpretation. Configure automated security monitoring throughout the migration process. Verify secure communication between all migration components before execution.
- Perform repeated migration experiments under controlled conditions to evaluate framework reproducibility.
- Perform migration experiment. Conduct ten independent migration experiments for both the baseline and proposed environments. Maintain identical hardware, software, and network configurations throughout all experiments.
- Migrate 10 GB of healthcare data during each experimental run. Repeat all experiments under identical workload conditions. Record security events, migration logs, anomaly detection outputs, and execution times during every experiment.
- Validate migration integrity. Calculate SHA-256 checksums before and after migration. Verify complete data integrity after every migration experiment. Document checksum validation results.
- Calculate quantitative security, migration, and anomaly detection metrics for comparative evaluation.
- Measure security performance. Measure credential exposure duration. Calculate the number of exposed credentials during migration. Measure incident detection time. Record public network exposure duration.
- Evaluate anomaly detection performance. Calculate anomaly detection accuracy, precision, recall, F1-score, and area under the receiver operating characteristic curve (AUC). Evaluate migration performance. Measure total migration latency and calculate migration throughput. Record communication overhead introduced by security mechanisms.
- Perform statistical validation. Calculate the mean and standard deviation for all performance metrics. Compute 95% confidence intervals. Perform paired Student's t-tests to compare the baseline and proposed frameworks. Consider statistical significance at p < 0.05. Representative performance evaluation results generated during the experimental comparison are shown in Figure 6.
- Table 7 summarizes the quantitative performance comparison between the baseline and the proposed migration framework.
Table 8 summarizes common implementation issues encountered during secure database migration, their possible causes, and recommended corrective actions.

Figure 6: Performance comparison between the baseline migration framework and the proposed zero-trust, explainable AI-enabled secure cloud migration framework. (A) Comparison of credential exposure duration using long-term and temporal least-privilege credentials. (B) Comparison of anomaly detection performance metrics, including accuracy, precision, recall, F1-score, and AUC. (C) Comparison of migration latency across ten independent experimental runs, showing that the latency increase remained below the predefined acceptance threshold. (D) Statistical comparison of key performance metrics using paired Student's t-tests, showing mean differences and 95% confidence intervals. Error bars represent 95% confidence intervals from ten independent experimental runs. This figure was generated by the authors using Python 3.11 (Matplotlib 3.9) and formatted using Microsoft PowerPoint (Microsoft 365). Please click here to view a larger version of this figure.
| Performance Metric | Baseline Framework (Mean ± SD) | Proposed Framework (Mean ± SD) | Improvement | 95% Confidence Interval | p-value |
| Credential Exposure Duration (h) | 24.70 ± 1.32 | 0.42 ± 0.18 | 98.3% reduction | 23.6–24.9 | <0.001 |
| Anomaly Detection Accuracy (%) | 72.4 ± 2.1 | 94.6 ± 1.3 | +22.2% | 20.8–23.5 | <0.001 |
| Precision (%) | 68.1 ± 2.5 | 92.7 ± 1.5 | +24.6% | 23.1–26.0 | <0.001 |
| Recall (%) | 70.3 ± 2.4 | 93.1 ± 1.6 | +22.8% | 21.4–24.2 | <0.001 |
| F1-score (%) | 69.2 ± 2.2 | 92.9 ± 1.4 | +23.7% | 22.3–25.0 | <0.001 |
| AUC | 0.78 ± 0.03 | 0.97 ± 0.01 | +0.19 | 0.17–0.21 | <0.001 |
| Migration Latency (min) | 87.6 ± 3.2 | 97.4 ± 2.9 | 11.2% overhead | 8.9–10.7 | 0.002 |
| Data Integrity (%) | 99.8 | 100.0 | 0.2% improvement | 0.1–0.3 | 0.031 |
| Public Network Exposure | Enabled | Eliminated | 100% eliminated | N/A | <0.001 |
Table 7: Baseline and proposed secure database migration frameworks: A performance comparison. The table displays credential exposure duration, anomaly detection effectiveness, migration latency, data integrity, and security enhancements assessed quantitatively during the protocol validation.
| Issue | Possible Cause | Recommended Solution |
| Migration authentication failure | Expired or invalid temporary credentials | Regenerate temporal credentials and verify IAM policies before restarting migration. |
| High migration latency | Network congestion or insufficient bandwidth | Optimize network routing, schedule migration during low-traffic periods, and verify endpoint connectivity. |
| False-positive anomaly alerts | Improper Isolation Forest contamination threshold | Tune contamination parameter using the validation dataset and retrain the model. |
| Unstable SHAP explanations | Insufficient or non-representative background samples | Increase the SHAP background sample size and ensure representative sampling. |
| Data integrity mismatch | Interrupted migration or corrupted data transfer | Re-run migration after validating SHA-256 checksum values and source/target consistency. |
| Secure endpoint connection failure | Firewall or TLS configuration errors | Verify SSL/TLS certificates, firewall rules, and private endpoint configuration. |
| Low anomaly detection accuracy | Incomplete feature extraction or poor preprocessing | Review feature engineering, normalize security features, and retrain the model. |
| Model convergence issues | Inappropriate hyperparameters | Adjust learning parameters and validate model performance before deployment. |
Table 8: Troubleshooting guide for secure healthcare database migration. The table lists frequent migration errors, their possible roots, corrective measures advised, and expected results to ensure a reliable execution of the secure migration protocol.