Nihilist Cipher: Encrypt and Decrypt Online

in "Polybius Square Ciphers"

Nihilist cipher is a polyalphabetic cipher and a variant of Polybius square. First, the cipher creates a Polybius square for a given key, and then an additional key for creating the ciphertext.

It uses an alphabet written into a 5 by 5 block where addresses of each letter are used for the cipher, for example, 23 and 37.

The order does not matter but there should be no repetition. Also, the alphabet often starts with the keyword.

Nihilist cipher was first used in the eighties of the 19th century in Russia by Nihilist organizations.

Therefore, the cipher is named after the Nihilist movement, who fought against czarism in Russia and attacked czarism’s officials in the 19th century.

They killed the tsar Alexander the second in the successful assassination in 1881.

The original algorithm was not very strong but there are some modifications which provide much better security. One of ciphers which belongs to the Nihilist family is the VIC cipher.

How to encrypt using Nihilist cipher?

The Nihilist cipher is an over-encryption of the Polybius square. It uses a grid (usually 5 by 5 = 25 cells) that is filled with letters of the alphabet (often a deranged alphabet).

For a 5 by 5 grid, the 26-letter Latin alphabet do not fit, so, we have to choose a letter to omit, often the J, V or W is omitted.

The grid has digits headers for its rows and columns (typically 1 to 5).

For example:

\

1

2

3

4

5

1

A

B

C

D

E

2

F

G

H

I

J

3

K

L

M

N

O

4

P

Q

R

S

T

5

U

V

X

Y

Z

 

To encrypt a text, it is necessary to replace each letter of the initial text, by its coordinates in the grid.

Generally, the coordinates (row, column) and rarer (column, line) are used. A numerical code consisting of pairs of digits is obtained.

For example, A is therefore encoded as 11 (because in row 1, column 1), E becomes 15 (row 1, column 5).

For example, the message “KREMLIN” is encrypted as “31, 43, 15, 33, 32, 24, 34”.

The particularity of the Nihilist cipher in relation to the Polybius cipher is its over-encryption. The nihilists use a key that is added for each couple of digits previously created.

To keep only 2 digits, subtract 100 from the amounts that would be greater than 100.

For example, the key “VODKA”, which is encoded as “52, 35, 14, 31, 11” is added (value after value) to the encrypted text.

For example:

Plain Message

K

R

E

M

L

I

N

Coded (Message) Letters

31

43

15

33

32

24

34

Key (repeated)

V

O

D

K

A

V

O

Coded (Key) Letters

52

35

14

31

11

52

35

Final Message (Addition)

83

78

29

64

43

76

69

 

For example, the final encrypted message is 83782964437669.

How to decrypt a Nihilist ciphertext?

Decryption requires to know the grid and the over-encryption key.

For example, take the encrypted “577066392880”, the key “CODE” and the grid below.

\

1

2

3

4

5

1

A

B

C

D

E

2

F

G

H

I

J

3

K

L

M

N

O

4

P

Q

R

S

T

5

U

V

X

Y

Z

 

To decrypt, the coded key is subtracted from each pair of 2 digits and each number obtained is replaced by the corresponding letter with these coordinates in the grid.

For example, the key “CODE” is encoded with the grid as (13, 35, 14, 15), it is then subtracted from the message.

For example:

Coded Message

57

70

66

39

28

80

Coded Key (repeated)

13

35

14

15

13

35

Subtraction

44

35

52

24

15

45

Letter in the grid

S

O

V

I

E

T

 

For example, the plain message is “SOVIET”.

Use the above Nihilist cipher decoder and encoder to encrypt/decrypt simple messages.

How to recognize a Nihilist ciphertext?

The message is composed of an even number of digits.

In general case of using 5 by 5 grid with coordinates from 1 to 5, the message is composed of numbers between 0 and 100 except for values between 11 and 21 inclusive, which never appear in this case during the encryption process.

Any reference to Russia (USSR), tsars or Russian traditions is a clue.

The word nihilist is generally associated with a philosophic doctrine, but in Russia the word нигилизм has a Latin root meaning nothing.

How to decipher a nihilist text without key?

You can analyze the pairs of digits of the message to extract the potential additions that formed them. It is possible to find all the possible combinations and to deduce the potential keys with the grid.

What are the variants of the nihilist cipher?

It is possible to make several variants:

Inversion of coordinates: rather than using (row, column), it is possible to use (column, row).

Change of coordinates names: the digits from 1 to 5 can very well be mixed or replaced by other digits.

Multiple keys: it is possible to use several keys, summed successfully, but this only extends the process time and does not complicate a brute-force attack.

Recommended Tools