INFERENCELAB
Back to Engineering Journals
Open-Source ResearchCohort 2026
medPQC

MedPQC 1.0.0: Engineering a Hybrid Post-Quantum Cryptographic Framework for Medical Image Security

MedPQC 1.0.0 is a research-oriented Python framework developed by INFERENCE Lab to investigate hybrid post-quantum cryptography for medical image security. It integrates ECDH, ML-KEM-768-aligned key encapsulation, Lorenz-system-based image transformation, and authenticated encryption mechanisms. The initial evaluation explores encryption performance, statistical image properties, and bit-exact reconstruction across medical imaging datasets. The accompanying research paper is in progress, with MedPQC 1.1.0 planned to introduce further technical amendments and improvements.

Published: 2026-11-01 7 min read

Lab Note & Technical Documentation

The Security Challenge

Medical imaging infrastructure has become increasingly dependent on interconnected Picture Archiving and Communication Systems (PACS), cloud-based storage, and distributed telemedicine environments. These systems routinely handle sensitive radiological information, including X-rays, computed tomography (CT), and magnetic resonance (MR) images. Protecting such information requires more than conventional encryption. It requires confidentiality, integrity, reliable reconstruction, and consideration of emerging cryptographic threats.

One particularly important concern is the Harvest Now, Decrypt Later (HNDL) threat model, in which adversaries collect encrypted information today with the possibility of decrypting it when sufficiently capable quantum computers become available. Classical public-key cryptographic mechanisms, including RSA and elliptic-curve-based key exchange, face potential vulnerabilities under sufficiently powerful quantum computation.

MedPQC was initiated at INFERENCE Lab to investigate an alternative cryptographic architecture that brings post-quantum key encapsulation, authenticated encryption, and image-specific transformation mechanisms into a unified software implementation.

Architectural Design and Implementation

The first public release, MedPQC 1.0.0, introduces a hybrid cryptographic architecture combining Elliptic Curve Diffie-Hellman (ECDH) over NIST P-256 with a Ring Learning With Errors (RLWE)-based post-quantum key encapsulation implementation aligned with the ML-KEM-768 parameter set specified in NIST FIPS 203.

The resulting shared secrets are processed through an HKDF-SHA3-512-based derivation mechanism to establish encryption and authentication material.

Beyond key establishment, the framework incorporates a Lorenz dynamical system integrated through fourth-order Runge-Kutta (RK4) numerical approximation. Its output feeds a chaotic transformation pipeline involving coordinate permutation and multi-round bit-plane diffusion. Numba Just-In-Time (JIT) compilation is employed to improve computational efficiency.

The authenticated encryption layer combines AES-256-GCM with HMAC-SHA3-256. This provides an additional authentication mechanism around encrypted payloads, with verification performed before decryption.

An important engineering consideration is preservation of medical image information. Unlike ordinary visual media, medical images may contain clinically relevant numerical values, particularly in 16-bit CT representations and Hounsfield Unit data. Consequently, the implementation targets bit-exact reconstruction rather than perceptual similarity.

Experimental Evaluation

The initial evaluation includes 5,856 images from PneumoniaMNIST, a balanced cohort of 100 chest radiographs, and additional experiments involving higher-resolution radiographs and 16-bit CT and MR representations.

Reported experiments examine encryption latency, adjacent-pixel correlation, Shannon entropy, and reconstruction error. Across the reported PneumoniaMNIST evaluation, the implementation achieved a 100% lossless recovery rate, with zero reconstruction mean squared error.

The balanced 100-image evaluation reported mean encrypted-image entropy of 7.9972 bits per pixel and adjacent-pixel correlation of approximately 0.00304.

These measurements provide useful indicators of image transformation behaviour. However, statistical image metrics alone cannot establish cryptographic security. Formal cryptographic analysis, independent implementation audits, and adversarial evaluation remain necessary.

Continuing Development

The release of MedPQC 1.0.0 represents an initial publicly accessible engineering implementation, not a declaration of production readiness or clinical deployment.

The accompanying research manuscript, Hybrid Post-Quantum Key Encapsulation with Lorenz Chaotic Diffusion for Authenticated Medical Image Encryption, is currently under development. Ongoing work focuses on strengthening cryptographic correctness, reviewing protocol assumptions, improving implementation robustness, and expanding experimental validation.

A subsequent release, MedPQC 1.1.0, is planned with further amendments and engineering improvements following continued testing and review.

Research and Engineering Perspective

At INFERENCE Lab, we approach research software as an evolving engineering artefact. A successful implementation must remain open to examination, reproducibility, criticism, and refinement.

MedPQC reflects this philosophy: translating a research hypothesis into an accessible software package while maintaining a clear distinction between experimental results and established security guarantees.

The objective is not simply to implement another encryption library, but to investigate how emerging cryptographic mechanisms can be engineered, evaluated, and progressively strengthened for the protection of sensitive medical information.

Project Repositories & Artifacts

Technologies
Post Quantum CryptographyMedical Image Encryption