## 3 The Proposed Scheme  
We consider a typical Internet of Medical Things (IoMT) environment, where the quantum key agreement (QKA) protocol operates between two main entities: the Patient's Device (PD) and the Healthcare Provider (HP). The PD represents a IoMT terminal, such as a wearable or implantable medical device, which continuously collects physiological signals (e.g., heart rate, glucose levels) from the patient. The HP denotes a trusted medical infrastructure component, such as a hospital cloud platform or electronic health record (EHR) system, which securely manages patient data and supports remote monitoring and diagnosis. The primary objective of the QKA protocol in this context is to enable the PD and HP to jointly establish a shared quantum key used to encrypt and authenticate sensitive medical data during transmission. Unlike conventional QKD schemes, which rely on a single party (typically the HP) to generate and distribute the key, the QKA protocol ensures that both the PD and HP equally contribute to the final key, thereby achieving fairness and reducing the risk of unilateral control. Communication between PD and HP occurs over a quantum channel for qubit transmission for protocol coordination. The system assumes that the quantum channel is lossy and noisy--conditions typical of real-world IoMT deployments--while the classical channel is assumed to be public but not necessarily authenticated. This model aligns with realistic constraints in IoMT networks, where authenticated classical infrastructure may not always be available or practical. Security threats in this model include both external eavesdropping and internal misbehavior (e.g., one party attempting to dominate the key generation). Therefore, the proposed QKA protocol must uphold correctness, security, and fairness, even under such adversarial settings. Furthermore, the protocol should be efficient and secure. The decoy photon technique is employed to safeguard transmissions against external eavesdroppers through the process of inserting decoy qubits to detect potential eavesdropping. The proposed scheme consists of the following phases:  
_Initialization (Public Parameters):_  
PD and HP agree on a public oracle \(O_{f_{i}}\big{|}f_{i}\in\{00,01,10,11\}\), \(i=1,2,\ldots,n\big{\}}\), which allows for the computation on the initial quantum states of two-qubit GSA where \(O_{f_{i}}\) corresponds to a bit string \(f=\{f_{i}|f_{i}\in\{00,01,10,11\},\ i=1,2,\ldots,n\}\) which serves as a one-time-pad. They also agree on a set of allowed initial quantum states \(|\psi\rangle=|++\rangle\). _Private Key Selection:_  
PD and HP randomly select their private key \(K_{PD}=\big{\{}k_{i}^{PD}\big{|}k_{i}^{PD}\in\{00,01,10,11\},i=1,\)\(2,\ldots,n\big{\}}\) and \(K_{HP}=\big{\{}k_{i}^{HP}\big{|}k_{i}^{HP}\in\{00,01,10,11\},i=1,2,\ldots,n\big{\}}\), respectively. _Public Key Computation:_  
PD and HP apply the Grover oracle \(O_{f_{i}}\) and their respective second Grover oracle \(O_{k_{i}^{PD}}\) and \(O_{k_{i}^{HP}}\), prepared using their private key, to the common initial quantum states \(|\psi\rangle\). This results in their respective public key \(O_{k_{i}^{PD}O_{f_{i}}}|\psi\rangle\) and \(O_{k_{i}^{HP}O_{f_{i}}}|\psi\rangle\). _Public Key Exchange:_  
PD and HP send their public keys to each other through the following operations. 1. PD and HP each prepare two decoy photons randomly chosen from one of the four non-orthogonal states, \(|0\rangle\), \(|1\rangle\), \(|+\rangle\), and \(|-\rangle\). Each participant inserts these decoy photons into the sequence representing their public key at random positions to create a new sequence. Then, they send their respective sequences to each other via the quantum channel. 2. PD and HP announce the positions and bases of the decoy photons in the new sequence. They then measure these photons according to the corresponding bases and respond to each other to detect potential eavesdropping. They compute the error rate; if it exceeds a predetermined threshold value, they abort the protocol and restart.