Introduction to Random Numbers

Random numbers are extremely important to cryptography. Let us understand why? They are unpredictable and the unpredictability makes it harder to decrypt. If the key was predictable then you would anticipate the key, which would make encryption easy to break.

What makes a number random? You do not know that is expected. Like I mentioned before, they are unpredictable.  What is also important, is the fact that each number is equally likely, it means that the random number n is equality likely to come up as the number m. In statistic, we call this property UNIFORM DISTRIBUTION. An example of this scenario is the rolling of a fair dice. The chances of getting a 5 is the same as the chances of getting a 3.

In Cryptography, we need random numbers to create encryption keys. How do we get them? We use computers. Computers use mathematical algorithms to generate random number. We are going to call these computer generated random numbers, pseudorandom numbers. Are these numbers good enough to classify these numbers random? Maybe.

Are these computer generated random numbers unpredictable? I am going to leave this question for you to discuss in the discussion area.

Before we go any further in Random Numbers, it is important to understand a little about Entropy. Entropy is the measure of chaos or uncertainty. It is an interesting branch of mathematics. It is quite possible to compute the entropy of a probability distribution. We can look at a pseudo random number generator and define a level of entropy that is acceptable. Am application of this concept is determining if a coin is loaded. We can look at the measure of entropy.

I hope I am not getting too mathematic for you. I promise, this is the hardest mathematics we are going to cover. I cannot promise the same thing for statistics 

In order to help you with understanding this concept, I am pointing you to two videos by Instructor Eddie Woo, a high school instructor in Australia – https://www.youtube.com/watch?v=fEWigU1dcp8

Additionally, go to Random.org and generate 20 random numbers. Do you think the number are predictable?

More details

Additionally, this week, we are going to learn general facts about Cryptography. Cryptography takes clear text and “encrypts” clear text so that an adversary will not be able to “read” the clear text message. The word plain text is used to refer to the original message and ciphered text is often used to refer to the resulting text after encryption has been applied.

It is extremely important to realize that the algorithms used for encryption have to be made public so that developers can implement them in software. Also, the computing community has to agree on a standard algorithm to use for encryption. If each user were to use a different encryption algorithm, the process would not become impractical since every time a user exchanges encrypted data with another user, they will also have to indicate the algorithm being used. In the USA, the entity responsible for developing encryption standard is the National Institute for Standard and Technology (NIST). The currently approved standard is called Advanced Encryption Standard (AES). We’ll discuss AES in more details as we progress through the course.

This week we are going to focus on the Language of Encryption. There is a computing language for writing encryption modules in software and it is called Cryptol (www.cryptol.net). Cryptol is an interesting language but it has not gained momentum. There are not many users of Cryptol but it is fairly new. Python is probably the best language to develop encryption modules for applications. Perl is also good and C/C++ are at the lower end of the spectrum for developing cryptographic modules.

This module is not about programming languages to develop crypto modules but it is about terminologies used in Cryptography.