## On the Subject of The Orange Cipher

Orange you glad to decipher me.

On the module, you will see 3 screens, a keyboard, 2 arrows, and a submit button that displays the current page you're on.

Pressing the right arrow takes you to the next page. Pressing the left arrow takes you to the previous page. There is a total of 2 pages.

On page 1, the top screen shows a 6 letter encrypted word, the middle screen shows a 6 letter string, the bottom screen shows an encrypted string. If the encrypted word has any Js, replace each J with the letter in the same position as the string in the middle screen. After you do all 3 steps, change the letter(s) back into a J.

On page 2, the top screen shows another encrypted string, the middle screen shows a word, and the bottom screen show a number.

### Step 1: Collon Cipher

First thing we need to do is to create a 5×5 matrix.

To do so, take the keyword from the middle screen on page 2, replace any Js with Is, and remove any duplicates.

Take the entire alphabet (not including the J) and remove any letters that is shown in the keyword.

If the last digit of the serial number is even, place the alphabet at the end of the keyword. Otherwise, place the alphabet at the beginning of the keyword.

Take the 25 length string and arrange it into a 5×5 matrix of letters. From now on, this will be called Matrix A.

Concatenate the 2 encrypted strings on the bottom screen of page 1 and the top screen of page 2.

Split the encrypted string into pairs and follow the instructions below for each pair:

• Find the 1st letter of the pair in Matrix A and use that as the row.
• Find the 2nd letter of the pair in Matrix A and use that as the column.
• The intersection of the 2 letters will give you a decrypted letter.

The resulting letters will form a keyword that will be used in step 3. Keep in mind that because of the absence of the letter J, that the word might have Is that were originally Js.

#### Example

Encrypted Word: XFDFCTCGAL
Key A: MUSCLARBDEFGHIKNOPQTVWXYZ

MUSCL
ARBDE
FGHIK
NOPQT
VWXYZ

XF -> V
DF -> A
CT -> L
CG -> U
AL -> E
Decrypted Keyword: VALUE

### Step 2: Bazeries Cipher

For this step, you will need 2 matrices. The first matrix, which will be called Matrix B, is already created here:

AFLQV
BGMRW
CHNSX
DIOTY
EKPUZ

The second matrix, Matrix C, will need to be created by using the 4 digit number on the bottom screen of page 2.

Turn each digit in the number into their word formats. Ex: 3097 -> THREE ZERO NINE SEVEN. This will be the keyword to use for Matrix C.

Turn any Js into Is, remove all spaces and duplicates. Take the entire alphabet (not including the J) and remove any letters that is shown in the keyword.

If the second digit of the serial number is odd, place the alphabet at the end of the keyword. Otherwise, place the alphabet at the beginning of the keyword.

Take the 25 length string and arrange it into a 5×5 matrix of letters, creating Matrix C.

With the encrypted word on the top screen of page 1, divide it into subgroups of X letters where X equals the sum of the digits from the bottom screen of page 2, modulo 4, plus 2.

For each subgroup, reverse the letters inside of it.

#### Example

3 + 0 + 9 + 7 = 19 % 4 = 3 + 2 = 5
DGPGKF => DGPGK F => KGPGD F => KGPGDF

For each letter, find the letter in Matrix C, then take the same row/col you found it and use that as the row/col for Matrix B to get a new letter.

The resulting letters form your new encrypted word.

#### Example

Encrypted Word: KGPGDF
Key B: AFLQVBGMRWCHNSXDIOTYEKPUZ
Key C: ABCDFGKLMPQUWXYTHREZONISV

AFLQV|ABCDF
BGMRW|GKLMP
CHNSX|QUWXY
DIOTY|THREZ
EKPUZ|ONISV

K -> G
G -> B
P -> W
G -> B
D -> Q
F -> V
New Encrypted Word: GBWBQV

### Step 3: Foursquare Cipher

As the step suggests, it requires 4 matrices. Matrix A, B, C that was used for steps 1 and 2 will be used here. Matrix D will be created by using the keyword that you got from step 1.

Turn any Js in the keyword into Is and remove any duplicates. Take the entire alphabet (not including the J) and remove any letters that is shown in the keyword.

If the first digit of the serial number is even, place the alphabet at the end of the keyword. Otherwise, place the alphabet at the beginning of the keyword.

Take the 25 length string and arrange it into a 5×5 matrix of letters, creating Matrix D.

Take the 4 matrices and form a 2×2 grid of them:

A | B
---
C | D

Split the encrypted word you got from step 2 into letter pairs. For each pair do the following:

• Find the 1st letter in Matrix B. Find the 2nd letter in Matrix C.
• Take the 1st letter's row and the 2nd letter's column to get the 1st decrypted letter in Matrix A.
• Take the 1st letter's column and the 2nd letter's row to get the 2nd decrypted letter in Matrix D.

Remember to replace any letters that were Js initially to a J to get your deciphered word.

#### Example

Encrypted Word: GBWBQV
Key A: MUSCLARBDEFGHIKNOPQTVWXYZ
Key B: AFLQVBGMRWCHNSXDIOTYEKPUZ
Key C: ABCDFGKLMPQUWXYTHREZONISV
Key D: VALUEBCDFGHIKMNOPQRSTWXYZ

MUSCL|AFLQV
ARBDE|BGMRW
FGHIK|CHNSX
NOPQT|DIOTY
VWXYZ|EKPUZ
-----+-----
ABCDF|VALUE
GKLMP|BCDFG
QUWXY|HIKMN
THREZ|OPQRS
ONISV|TWXYZ

GB -> RA
WB -> RE
QV -> LY
Decrypted Word: RARELY

Once you finally have your decrypted word, you can submit it. Once you start typing, all the screens will go black and the bottom screen will show what you are typing.

To clear it, just click one of the arrows. This goes to one of the pages and clears any input you put in. It will not let you go over 6 letters on input.

Once you are satisfied with your input, press the button labeled "SUB" to submit your answer. On a strike, the module will go back to the first page of the module, but it does not regenerate.