Questions tagged [hill-cipher]

The Hill cipher is a historic polygraphic substitution cipher invented by Lester S. Hill in 1929.

The Hill cipher is a historic polygraphic substitution cipher invented by Lester S. Hill in 1929. It was the first substitution cipher to allow operations on groups of more than three plaintext characters at a time.

The Hill cipher is based on linear algebra, specifically matrix multiplication. It works by mapping the plaintext letters into numbers, dividing the resulting number sequence into blocks of n numbers, each of which is interpreted as an n element vector and multiplied with an invertible n × n key matrix (using modular arithmetic) to obtain the corresponding block of ciphertext. Decryption works the same way, except that the key matrix is replaced with its inverse.

On its own, the Hill cipher is insecure, being vulnerable to a simple known plaintext attack: an attacker who knows the plaintext corresponding to at least n blocks of ciphertext can solve a system of linear equations to (with high probability) recover the full key matrix. In U.S. patent 1,845,947, describing a mechanical implementation of the cipher for n = 6 (with a fixed key matrix), Hill recommended combining the cipher with a non-linear monographic substitution to thwart such attacks.

45 questions
5
votes
2 answers

Hill cipher, unknown letter value

I've been struggling on this problem for a while now : the Hill cipher is well-known to be vulnerable to known-plaintext attack due to its linearity. Given a key matrix $K$ of size $n\times n$, one can retrieve the key with as little as $n^2$…
trispo
  • 151
  • 3
4
votes
1 answer

Hill-cipher, disordered alphabet

I am going to apply a simple substitution cipher to my input, then encrypt the result with a Hill cipher. How can this be broken, in a chosen-plaintext threat model? In other words, instead of the standard mapping of letters to numbers (A=0, B=1,…
user9
  • 43
  • 4
4
votes
2 answers

Are there ready-to-use software that can try many decryption techniques on a ciphertext, with no information?

Let's say I receive a 1 MB encrypted file, but I get no information about the encryption method, and no password. The only thing I can guess is that the person probably used a weak encryption method on a text file. Are there ready-to-use software…
Basj
  • 563
  • 5
  • 25
4
votes
3 answers

Hill Cipher known plaintext attack

I know a plaintext - ciphertext couple of length 6 for a hill cipher where its key is a [3x3] matrix. Based on what I've read and learned, to attack and crack keys of [n x n], if we know a plaintext - ciphertext duo of length $n^2$ then we have our…
ecem
  • 141
  • 1
  • 1
  • 4
4
votes
1 answer

Hill's Cipher - Known Plaintext Attack

I know this question has already been asked few times but I'm struggling a bit on a problem. I have a plaintext FRIDAY and its ciphertext PQCFKU, using $M = 2$, with corresponding integers $x = fr id ay = (5, 17),(8,3),(0,24)$ and $y = pq cf ku =…
4
votes
2 answers

Figuring out key in hill cipher (chosen-plaintext attack)

I have been wondering what approach to take in order to figure out what key was used to encrypt a message using the hill cipher. I know it is possible to obtain it even if it were just a known-plaintext attack, so it should be fairly possible for a…
Emyr
  • 571
  • 1
  • 5
  • 6
3
votes
2 answers

An unbreakable Hill cipher?

Why don't we use a Hill cipher of 100 × 100? Or even bigger? That would be close to unbreakable. The number of possible keys in a 2 × 2 Hill cipher is 157248. For 100 × 100 the number is beyond limits.
3
votes
1 answer

Calculating the inverse modularity of the determinant for Hill cipher

I'm trying to decrypt a message encrypted with Hill Cipher, but I don't understand how to find the determinant so it solves the equation $det * 1/det = 1 mod 26$. The determinant for my key matrix is $62$.
maya-bf
  • 33
  • 1
  • 3
3
votes
1 answer

Can Hill Cipher be considered as Asymmetric?

I know hill cipher is a block chipher ,We produce decryption key by inverse of key matirx but we still use different key for decryption. Therefore Can we say that Hill cipher is asymmetric chipher?
ccca
  • 85
  • 1
  • 1
  • 3
2
votes
0 answers

What are some statisitcal characteristics of a hill cipher?

Given a ciphertext, after performing a frequency analysis on it, how would you identify it as a hill cipher? What should i expect to see in the statistics?
2
votes
1 answer

Block cipher linearity (in relation to hill ciphers)

So while I knew hill ciphers were a form of block cipher (I'm assuming all the ones I have solved to date were ECB or something similar), so that got me thinking. Is it possible to use hill ciphers in other modes (ctr, ecb, cbc etc) on a binary…
Anan
  • 65
  • 1
  • 7
2
votes
1 answer

Hill cipher: How to find an unknown key of unknown size

How would you tackle the problem of finding the key (you don't know the length) to a Hill cipher when knowing only one 12-letter word of plaintext and its corresponding ciphertext? CONVERSATION has been encoded as SQZHUSSUDYKP with standard alphabet…
2
votes
0 answers

How can I determine the Hill cipher key in this case?

I have been struggling with a Hill cipher problem for many days, without any luck. I have the following ciphertext, which I know is an encrypted excerpt from an Edgar Allan Poe story: hcrjrg--dizj lt mcne lmisne dsdi sqqznbld bvt idyl ry dlt vftpj…
2
votes
1 answer

Security analysis of a "one-time pad" type hill cipher

Suppose the Hill cipher were modified to something like a one-time pad cipher, where Alice wants to send a message to Bob, and she chooses a key matrix randomly everytime a new message is sent (and the inverse of the key matrix is sent to Bob by…
user996522
  • 315
  • 2
  • 7
2
votes
1 answer

Hill Cipher question

Recently, I was given three ciphers to crack for my cryptography class. At this point, I have guessed that one of them is likely a Hill cipher (probably 3x3, as that is the most complex we have done so far). I have made a fairly good guess of two…
1
2 3