In the Rabin cryptosystem, choose distinct large odd primes , publish , and encrypt as . Usually , so a square root modulo each prime is obtained by exponentiating to or . Combine the two independent choices of signs by the Chinese remainder theorem to obtain the four roots modulo for a message coprime to . Redundancy or a specified encoding distinguishes the intended message. Factoring makes decryption easy; a general square-root oracle conversely factors by obtaining two roots not congruent up to sign and taking their greatest common divisor with .
For the Repeated-message attack on the Rabin cryptosystem, first compute . If , use the two ciphertexts to reconstruct with and . Since , we have , so this reconstruction is the ordinary integer . Therefore
If distinct semiprime moduli have , they share a prime; the gcd instead exposes their factors, allowing ordinary Rabin decryption with the usual encoding check. The two cases cover the stated protocol with distinct standard moduli.
In the coprime case, learning this message does not normally reveal the factors or a decryption key, so other messages encrypted only once remain protected by the square-root problem. Exceptional messages with do reveal a factor, and the shared-prime-modulus case compromises other messages too. Repetition under fresh coprime moduli is the vulnerability used here, rather than a universal attack on every ciphertext.
No. The procedure exposes a square-root oracle for the Rabin cryptosystem. The verifier chooses , sends , and receives another square root . If
then the factorization from distinct square roots modulo a semiprime gives
For a product of two odd primes, a square normally has four roots, and a returned root lies outside the pair with probability about . Repeating chosen-square challenges therefore factors with overwhelming probability. The attacker can then compute square roots and impersonate Alice. This is the chosen-square attack on Rabin authentication, so the proposed protocol is insecure.
For Rabin cryptosystem, choose primes , publish , and encrypt as . The factors let the receiver take square roots modulo and and combine them using the Chinese remainder theorem; redundancy identifies the intended one of four roots.
For RSA cryptosystem, choose , select coprime to and with . Encrypt as and decrypt by raising to modulo . Rabin inversion is provably equivalent to factoring, while ordinary RSA lacks that reduction; Rabin's disadvantage is its fourfold decryption ambiguity.
In the Rabin cryptosystem, the public key is and encryption sends an encoded message to
Knowing , the receiver finds the two square roots modulo each prime and combines them with the Chinese remainder theorem to obtain four roots modulo ; prescribed redundancy identifies the intended one.
Omicron has
The Chinese remainder theorem determines uniquely modulo (assuming the independently generated moduli are coprime; a nontrivial gcd would itself factor them). Since , one has , so this residue is the ordinary integer . Taking its positive integer square root recovers .
This does not normally decrypt another ciphertext sent under only one modulus. The recovered pair reveals no nontrivial square root collision modulo that modulus and hence supplies no factorization; breaking a single Rabin instance remains equivalent to factoring its modulus.
In the Rabin cryptosystem, the public key is , usually with distinct secret primes . A message is encrypted as
Knowing and , the receiver finds the two square roots of modulo each prime and combines them by the Chinese remainder theorem, obtaining the four square roots modulo ; redundancy identifies the intended message.
Factoring plainly enables this decryption. Conversely, suppose an algorithm returns a square root of a chosen quadratic residue. Choose random invertible , submit , and receive a root . With probability at least , ; then
is a nontrivial factor. Thus decryption and factoring are equivalent up to a randomized polynomial-time reduction.
A Rabin cryptosystem chooses Blum primes , publishes , and encrypts as . Decryption takes square roots modulo and , combines them with CRT, and uses redundancy to select the intended one of four roots. Here , while the obvious root is . Thus
So is factored, allowing all future square roots and hence all ciphertexts to be decrypted.