# CTFlearn 305 - Vigenere Cipher

Write-up on CTFlearn’s challenge 305 - Vigenere Cipher. Blorby! Challenge author: yakatoi.

# Challenge

Crypto, 20 points

The vignere cipher is a method of encrypting alphabetic text by using a series of interwoven Caesar ciphers based on the letters of a keyword.

I’m not sure what this means, but it was left lying around: blorpy

gwox{RgqssihYspOntqpxs}

# Solution

This challenge is all about the Vigenère Cipher. This cipher has been invented by the French cryptographer Blaise de Vigenère in 1553.

Its base concept is simple: all the letters from the plaintext are shifted in the alphabet with the corresponding letters from the key.
For instance, `B`

shifted by `C`

becomes `D`

(shifted by 2) because `C`

is at position 2 in the alphabet (`A`

is at position 0).
If the plaintext is longer than the key, repeat the key until it fits the right length. Below is a little scheme I have made describing that.

For that challenge, the two needed components are given: the ciphertext (`gwox{RgqssihYspOntqpxs}`

) and the key `blorpy`

.
The curly brackets won’t be affected by the cipher, as they are not part of the alphabet.

Without further ado, let’s open up CyberChef to solve this challenge. CyberChef is an app allowing us to perform crypto functions (and more) quickly in the browser.

Go into the *Operations* menu, search for “Vigenère Decode” and select the corresponding block. Drag it into the *Recipe*.
Enter the key in the *Key* option and the ciphertext as input.

The flag should now be printed in the *Output* box.

Let me know what you think of this article on twitter @noxtal_ or leave a comment below!