{'fraction_non_alphanumeric': 0.02982456140350877, 'fraction_numerical': 0.006516290726817042, 'mean_word_length': 4.415196743554953, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
A Three-Stage Quantum Cryptography Protocol

We present a three-stage quantum cryptographic protocol guaranteeing security in which each party uses its own secret key. Unlike the BB84 protocol, where the qubits are transmitted in only one direction and classical information exchanged thereafter, the communication in the proposed protocol remains quantum in each stage. A related system of key distribution is also described.


Introduction
This paper presents a quantum protocol based on public key cryptogrpahy for secure transmission of data over a public channel. The security of the protocol derives from the fact that Alice and Bob each use secret keys in the multiple exchange of the qubit.
Unlike the BB84 protocol [1] and its many variants (e.g. [2]-[4]), where the qubits are transmitted in only one direction and classical information exchanged thereafter, the communication in the proposed protocol remains quantum in each stage. In the BB84 protocol, each transmitted qubit is in one of four different states; in the proposed protocol, the transmitted qubit can be in any arbitrary state.

The Protocol
Consider the arrangement of Figure 1 to transfer state X from Alice to Bob. The state X is one of two orthogonal states, such as 0 and |1 , or Alice and Bob apply secret transformations U A and U B which are commutative, i.e., U A U B = U B U A . An example of this would be U A = R(θ) and U B = R(φ), each of which is the rotation operator: The sequence of operations in the protocol is as follows: 1. Alice applies the transformation U A on X and sends the qubit to Bob.
2. Bob applies U B on the received qubit U A (X) and sends it back to Alice.
3. Alice applies U † A on the received qubit, converting it to U B (X), and forwards it to Bob.

Bob applies U †
B on the qubit, converting it to X.
At the end of the sequence, the state X, which was chosen by Alice and transmitted over a public channel, has reached Bob.
Eve, the eavesdropper, cannot obtain any information by intercepting the transmitted qubits, although she could disrupt the exchange by replacing the transmitted qubits by her own. This can be detected by • appending parity bits, and/or • appending previously chosen bit sequences, which could be the destination and sending addresses or their hashed values, or some other mutually agreed sequence.
Since the U transformations can be changed as frequently as one pleases, Eve cannot obtain any statistical clues to their nature by intercepting the qubits.

Key distribution protocol
A related key distribution protocol is given in Figure 2. Unlike the previous case, X is a fixed public state (say |0 or 1 √ 2 (|0 + |1 )). The objective is to generate a key that is a function of the transformations involved, which is not chosen in advance by either party. The protocol consists of two stages: 1. Alice and Bob use secret transformations, U A and U B , on the known state X, and exchange these qubits.
2. They again apply the same transformations on the received qubits, thereby each getting It is assumed that neither Alice or Bob will measure the received qubits, and will use them as the input to a quantum register.
In a variant of this scheme, two copies of the unknown state X may be supplied to Alice and Bob by a key registration authority.

Conclusion
The three-stage protocol provides perfect security in the exchange of data over a public channel under the assumptions that a separate classical protocol ensures the identity of the two parties, and errors (deliberate or random) are detected by means of parity check and confirming that a known bit sequence that was appended to the bits has arrived correctly.
Since the proposed protocol does not use classical communication, it is immune to the man-in-the-middle attack on the classical communication channel which BB84 type quantum cryptography protocols suffers from [5]. On the other hand, implementation of this protocol may be harder because the qubits get exchanged multiple times.