Basics of Cryptology – Part 4 (Modern Cryptanalysis – Shannon's Entropy and Brute-Force Attack)

preview_player
Показать описание
#cryptology, #cryptography, #cryptanalysis, #lecture, #course, #tutorial

In this video, we show the basics of cryptology (cryptology = cryptography and cryptanalysis).

This particular video introduces the Shannon's information entropy, which we use for a brute-force attack on a (keyspace-reduced) DES cipher.

First, we give a short historical overview on the term "entropy". Then, we discuss the Shannon's information entropy, which is a measure for the value of information of data. Finally, we use the Cost Function component in CrypTool 2 to have a look at entropy values of plaintext and ciphertext and we also use the CrypTool 2 KeySarcher component to break a DES cipher-encrypted ciphertext (with a search space of 24 bit).

Рекомендации по теме
Комментарии
Автор

Excellent tutorials using an excellent tool. Impressive!

MarkBoomaars
Автор

Hello, sorry for the double post! The other account often gets marked as spam.

Yes, the task is to find the encrypted hex encoded string from a text file of many other hex encoded strings. The string was encrypted by being XORed with a single character.

If you are interested, the problem is on the website "cryptopals" and it is problem 4 from problem set 1. Maybe you will enjoy these problems if you have not seen them already (:

If you don't have time, totally understandable. Thanks for the response! I have not had the time to written any code yet and try out ideas, so I hope to do so soon! Cheers.

Edit: For some reason I could not do a direct reply to your comment without getting an error, sorry about that

takyon
Автор

Very nice. This reminds me of the challenge from the first problem set on the website cryptopals, where you are given a file that consists of strings of 60 characters each. You must find which 60 char string has been XORed against a character. I have not tried it yet, but I suspect we can just compute entropy for every string based on the char frequency metric in this video, and check for which is highest in entropy to get our string. Just thinking out loud however, maybe there is a simpler way!

robscale
Автор

Nils, quick question. Does adding randomly chosen nulls as the encryption process happens add entropy?

Maybe I am not understanding completely, but entropy being "unpredictability" roughly speaking, it makes sense that as I am encrypting my message that adding random nulls would _increase_ this.

For example, let's say we have encrypted ATTACKATDAWN as

YFSVGINPQVDD

...then add randomly chosen nulls (but indicated somewhere to the recipient so decryption can occur properly) so the CT becomes:

YFRSVGIKNPQSVDTD

...does this add entropy?

aethrya
Автор

Great vid. This reminds me of the problem on "Cryptopals" in which you are given a text file with a bunch of strings, each string containing 60 characters, but one of them is XORed with a byte. I guess one plausible way to find that XORed string would be to find the string with highest entropy, right?

takyon