2
$\begingroup$

Can somebody analyze this scheme and explain how (in?)secure it is?

Assume that:

  • The keys were initially securely exchanged
  • All keys are truly random

In this scheme:

  • The key size is of length 2s, the plaintext is of length s, and the total message size is 3s
  • The first 2s contains a randomly-generated key to be used for the next message
  • The last s contains the plaintext.
  • The message in question uses the Vernam cipher
  • The first half of the key encrypts the next key, and the last half encrypts the plaintext

How secure is it to have every bit in the first half of the key (total size s) encrypt every two bits of the next key to be used?

  • Does this leak information about the keys?
  • Is it possible to actually deduce keys from that?

What if some sort of random mapping where each bit of the key does not encrypt consecutive bits of the next key was thrown into the mix?

Edit:

Example message layout:

| Next Key(size 2s) | Plaintext(size s) | | |^ This half is the key for the next plaintext ^ This half is used to encrypt the whole key (each bit encrypts 2 bits of the next key)

Edit 2:

Message: | Next Key Key | Next Key | Plaintext | ^Encrypts this-\/ ^Encrypts this-\/ Possible Random Mapping->\/ \/ [_________________________] \/ Next message: | Next Key Key | Next Key | Plaintext |

What is inherently insecure about each bit of a random key encrypting two bits of the next (entirely random) key in this scenario?

In addition, would adding a random mapping between the bits of Next Key Key and the next key add any security if the mapping was changed every message (some kind of mapping struct in the plaintext)?

If not, why? If this scheme is completely insecure, I wish to understand in what specific ways it may (as you say) leak information about the plaintext.

Edit 3:

Upon inspection, it turns out that one only needs to figure out HALF of the first key in order to crack the entire message chain. Each message makes it easier to find that half-key, since each message depends on the previous one.

$\endgroup$
1
$\begingroup$

Does this leak information about the keys?

It leaks information about the plaintext. For example, given the three ciphertexts, it's possible to compute the XOR of the second and third plaintexts. This is often enough to deduce the original plaintexts.

What if some sort of random mapping where each bit of the key does not encrypt consecutive bits of the next key was thrown into the mix?

To start, instead of trying to guess about how to make the process more complex, I would suggest thinking about how to rederive the attack I mentioned above. Learning about how to do cryptanalysis is the right place to start to learn how to design cryptography.

$\endgroup$
  • $\begingroup$ How would you compute it? I am a noob as far as cryptography, but right now the key encrypts the (random) key itself. Also, how would you go about calculating this if you did not know which bit in the key encrypted what bits in the next message? Also, thank you for the quick response! $\endgroup$ – anon Jun 6 '18 at 22:08

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.