Skip to main content
Challenges LSB (parity) oracle
Cryptography Hard LSB oracle Solves: 8

LSB (parity) oracle

Author: CyberSamSU
Points
90

Some servers decrypt the ciphertext and return only the last bit (even/odd) of the result — as if this is "harmless" information. In fact, even this single bit reveals the entire message.

The reason: the last bit of 2·m mod n tells us whether m < n/2 or m ≥ n/2 (since n is odd). By asking for the answer for 4·m, 8·m, … each time, we squeeze the message into the range of n/2, n/4, … using binary search.

The oracle has already answered 511 requests: the i-th answer = the last bit of (2^(i+1) · m mod n). These bits are in the attached oracle_javoblari.txt file (0/1 string, from left to right i = 0, 1, 2, ...).

n =

5156217139785565706737677144050559241104316233958988859924290902
6918367779233179154409271678069794392155013902806833733709761026
26639996768071178421440203

e = 65537,

c =

4074593035646570588079725312009964080874292993745836666869369461
1618545964448566099173986334935605915029836832901887767692070662
09483957171815343210270637

Use fractions (Fraction): [lo, hi] = [0, n], divide in half at each step. At the end, round hi to an integer and check that pow(m, e, n) == c.

Attached files
oracle_javoblari.txt Log in to download
SHA-256 checksums
oracle_javoblari.txt: e44fd1c21d1539691203b7e4db3a884742e9bea466da5f003b82bbcc0220e722
Theory: learn the topic
Learning paths: Cryptography 301
Hints 2
Opening a hint reduces the points you get for solving this challenge.
Hint 1 −9 pts Log in
Hint 2 −18 pts Log in
To submit a flag, log in.

First solvers

1. Абдул 15.09.2026
2. W.o.X 17.09.2026
3. Лазиз 04.10.2026
4. testrejim 09.10.2026
5. Mirjaxon Qaxxarov 26.10.2026
6. Odam 04.11.2026
7. arcanum 11.11.2026
8. AGENT X 28.11.2026