1
$\begingroup$

Enigma's biggest flaw was that a letter could never be encrypted as itself. How much would enigma's security increase if it were possible that a letter could be encrypted as itself? I know that would void the method used by Turing and co.

Please give as much detail as possible in answers.

EDIT: clarifying improvement

The improvement is, in the simplest terms:

Once the signal has passed through the rotors and into the reflector, the rotors shift forward before allowing the signal back through, meaning that each encryption operation would use two shifts instead of one.

EDIT 2: Also, with enigmas flaws removed, how comparable to modern algorithms would it's security be? And as another note, I'm not talking about modifying enigma back in WWII, I'm talking about a virtual software based mod now.

$\endgroup$
  • 2
    $\begingroup$ That will depend on how this flaw is removed, making the question too broad IMHO. If for example we add an additional fixed public involution (e.g. A to B, B to A, C to D, D to C..) on input on encryption, and output on decryption, we fully fix the flaw as stated in the question, but cryptanalysis is just as easy. If we make that additional permutation keyed, the system is more secure to some degree. $\endgroup$ – fgrieu Oct 22 '19 at 7:31
  • 1
    $\begingroup$ @fgrieu edited to describe more detail $\endgroup$ – Legorooj Oct 22 '19 at 9:16
  • 3
    $\begingroup$ My question would be how to do it - It is easy in a modern digital electronic world, but would be much more difficult in a WW2 time frame. $\endgroup$ – Eugene Styer Oct 22 '19 at 14:47
  • 1
    $\begingroup$ Well, if you enhance Enigma to have no flaws, well then, it'd have no flaws. However, I am not convinced that specific suggestion you gave would have no flaws. For example, in the short term, the encryption operation can be expressed as $R_i P R^{-1}_{i+1}$, for a fixed permutation $P$ with no fixed points (the rest of the rotors). It would seem to me that statistical analysis (based on the lack of fixed points) be able to recover the state of the initial rotor. Once you do that, you're left with a standard Engima (with one less rotor) $\endgroup$ – poncho Oct 23 '19 at 14:14
  • 1
    $\begingroup$ The conclusion I've come to is that it entirely depends on how enigma is modified. See @ponchos answer for detail on some attacks. $\endgroup$ – Legorooj Oct 24 '19 at 4:21
2
$\begingroup$

with enigmas flaws removed, how comparable to modern algorithms would it's security be?

With the specific change you specified, it would still (by modern standards) be considered "broken".

Here is how you can perform a distinguishing attack, and do a partial key recovery (recover the first two rotor settings with a good probability of recovering the third rotor setting) with about 400 characters of known plaintext.

I'll be assuming a 26 character rotor, however the attack scales to other sizes.

Here's how to recover the first rotor setting (and if you do recover a setting that works, that's a distinguishing attack):

  • In the encryption operation, the note that:
    • The plaintext character is sent through the first rotor: $A := R_i({Pt})$
    • The ciphertext character is sent through the first rotor after stepping it one position: $B = R_{i+1}(Ct)$
    • The mapped plaintext $A$ is different than the mapped ciphertext $B$

This holds because the internal rotors and the reflector do not step during the operation, and hence will never map a character to itself.

Note that this might not be true if the second rotor is stepped during the encryption operation; however that will occur only once every 13 character encryptions.

So, if we take a guess at an initial rotor setting, we can determine how all the plaintext and ciphertext characters are mapped. Then, if we find two instances where the plaintext and ciphertext characters are mapped to identical $A, B$ values (and those locations are not multiples of 13 apart), we know that that initial rotor setting is impossible.

After 400 characters, the probability that an incorrect rotor setting will show as possible is approximately $2^{-13}$; as there are significantly fewer than $2^{13}$ possible settings for the first rotor, then with high likelihood, only the correct setting will remain as possible (and if no settings remain, then this isn't modified Enigma).

Now, that we've recovered the first rotor setting (and position), we can peel off the first rotor operation (by applying the now-know first rotor operation to the known plaintext/ciphertext), and use a similar attack to recover the second rotor (which is actually easier; we have a lot more information per rotor step). And, if the third rotor steps during the 400 character encryption but not the fourth (probability >50%), then we can recover the third rotor (using the same trick)

Bottom line: this would be considered (by modern standards) totally broken

| improve this answer | |
$\endgroup$
  • $\begingroup$ Your attack seems to use th fact that a letter can not be encrypted as itself - would it still succeed if a letter could be? $\endgroup$ – Legorooj Oct 23 '19 at 23:59
  • $\begingroup$ @Legorooj: this specific attack, no. However, depending on how you modify Enigma, a more sophisticated one might be able to... $\endgroup$ – poncho Oct 24 '19 at 2:16
  • $\begingroup$ Well then, I shall tag you when I've done with my algo, and ask about its security in a new question. $\endgroup$ – Legorooj Oct 24 '19 at 2:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.