I have an exercise to do regarding Vigenère encryption.

and a partial plain text: S''''R''R''''R''''PASS'''''

The key length is unknown.

The question is: is it possible to find the key and the plain text? Regarding what I've seen in class, I don't think it's possible.

But I was wondering if it was possible in some way with a computer to find the rest of the plain text and the key?

PS: neither the plain text or the key are in English.

  • $\begingroup$ You have a got a massive crib there in "PASS". Did you try plugging in various possible plaintexts, like "password", "passport", "passing", etc... (in other languages, since English is not an option)? Then retrieve part of the key where you know the ciphertext and guessed the plaintext, you might get enough of the key to guess the rest (if it's a meaningful key like a word). $\endgroup$
    – Thomas
    Nov 11, 2012 at 9:26
  • $\begingroup$ @Thomas: The PASS is kind of a red herring in this case, though; it's not actually all part of the same word. $\endgroup$ Dec 9, 2012 at 8:54

2 Answers 2


First guess the key length(Just try every plausible length, there aren't many).

Then for each position where you know both plain- and ciphertext, calculate the key char. If you get a contradiction, the guessed key length was wrong. If the key length is short enough compared to the number of known pairs this will probably give you a large part of the key.

  • $\begingroup$ Thanks for your help, I'm really close to it. I've got almost all of the key which is hopefully : 4-13-?-?-5-4-19. The pattern seems correct but I don't find real words nor for the key or the plain text which has a few holes. Maybe it's not possible to build correct words so it's not "possible" to decrypt the cipher text. $\endgroup$
    – Pierre
    Nov 2, 2012 at 18:06
  • $\begingroup$ @Pierre: Just decode as much of the plaintext as you can and try guessing what the first word might be. (Also, the key itself is a meaningful phrase, too.) $\endgroup$ Nov 2, 2012 at 18:48


WNZTNV is repeated...
If i'm counting correct on position 1-6 and 22-27.
My guess would be the key length is a divider of 21? 7 seems to be consistent with the other information, but my knowledge of foreign languages is close to none, so i don't recognize anything readable in key or plaintext...

key DM''DDS of EN''EET (depending on your definition...) plain something like: SA''JRPAR''FURNE''PASS''JR

maybe too obvious?

  • 1
    $\begingroup$ Good observation about the repeat. Your guess at the partial key is close, too, although one of the letters is off by one. Anyway, I'm kind of trying not to reveal too much of the solution, since it's pretty obvious (from the plaintext!) that it was meant as a challenge to be worked out by the student. $\endgroup$ Dec 9, 2012 at 8:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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