$ cat writeup.md…
$ cat writeup.md…
hackthebox
Task: Quantum teleportation protocol where flag bits are encoded in qubit states. Solution: Apply Pauli correction gates based on measurement results and decode the flag from qubit 2 measurements.
$ cat /etc/rate-limit
Rate limit reached (20 reads/hour per IP). Showing preview only — full content returns at the next hour roll-over.
Every 24 hours, Qubitrix will release a secret message to our partners. Please follow the instructions we sent you by email from [email protected].
The server implements a quantum teleportation protocol. The flag is split into pairs of bits. Each pair is encoded into the state of qubit 0:
00 -> $|0\rangle$ (Z basis)01 -> $|1\rangle$ (Z basis)10 -> $|+\rangle$ (X basis)11 -> $|-\rangle$ (X basis)Then an entangled pair (Bell state) is created on qubits 1 and 2. CNOT(0,1) and H(0) operations are performed, after which qubits 0 and 1 are measured in the Z basis. The measurement results $M_0$ and $M_1$ are communicated to the user.
The user must:
According to the quantum teleportation protocol, the state of qubit 2 after measurements $M_0$ and $M_1$ differs from the original state of qubit 0 by Pauli operators:
The first bit of the pair is determined by the basis (Z -> 0, X -> 1), the second bit — by the measurement result of qubit 2 in that basis.
from pwn import * import re def solve(): # host = "94.237.122.188" # port = 52871 # r = remote(host, port) # For local testing or if server is running via docker r = remote("localhost", 1337) flag_bits = "" ...
$ grep --similar