Text book question of Chapter 9 of "Crypto and Network Security" by William Stallings:
When using the RSA Algorithm — if a small number of repeated encodings give back the plain text, what is the likely cause this happens?
Text book question of Chapter 9 of "Crypto and Network Security" by William Stallings:
When using the RSA Algorithm — if a small number of repeated encodings give back the plain text, what is the likely cause this happens?
The question is about the "cycling attack" against RSA. The attack needs to be considered, in principle, for any deterministic asymmetric cipher with the same input and output domain, including RSA (without padding): the attacker repeatedly encrypts the ciphertext, until she obtains the ciphertext again; the last value enciphered is the plaintext.
This is discussed in the paper Are Strong Primes Needed for RSA? by Ronald L. Rivest and Robert D. Silverman. They conclude that it simply does not work in practice: "Cycling attacks are extremely unlikely to be effective as long as the primes used are large. Indeed even probabilistic factoring attacks will succeed much more quickly and with higher probability than cycling attacks".
Hence the answer to the question is in practice: the RSA key is not the product of big-enough random-like primes with proper relation to $e$; or/and the input to the RSA exponentiation is not a random-like integer, but rather crafted with knowledge of the factors of $n$, implying that RSA is used without proper padding. Any of these would be Real Bad.
I'm assuming you are using "primitive RSA" (i.e. without padding), and encryption of a message $x$ is simply $x^{e}\, \bmod n$, with $(e, n)$ being the public key.
If for all messages we have $(...((x^e)^e)...)^e \bmod n = x = x^1$, with $k$ repetitions, we have actually $x^{e^k} \bmod n = x^1$, and this is equivalent (?) to $e^k\, \bmod \phi(n) = 1$ (and $d = e^{k-1}\, \bmod \phi(n)$, $d$ being the exponent in the private key.)
I have no idea what your textbook task wants to actually know here, but this might give you a start.
Suppose the public key is $n=p.q$
Probably the order of random encryption key $e$ relative to $(p-1)(q-1)$ is so small so that a small power of $e$ gives something congruent to $1 \bmod (p-1)(q-1)$.
For example: in the worst case where the order is $2$, then both $e$ and $d$ are the same.
Take $p=7$ amd $q=5$. Then $(7-1)(5-1) = 24$.
If $e=5$ then $d \cdot5\equiv 1 \pmod {24}$. Here, $d$ becomes $5$.