Question

In: Computer Science

Given the following password generator: ● |Σ| = 94 (the printable characters on a US keyboard)...

Given the following password generator:
● |Σ| = 94 (the printable characters on a US keyboard)
● |k| = 7
● Assume that the password generated is a random arrangement of k characters from Σ


a) What is the entropy of a password generated by this system (show your work)?
b) Assume an attacker has the hash and seed for a password generated by this system. The attacker also has a computer that can generate 1010 hashes per second. How long (in seconds,
hours, days, or years) will it take the attacker to find the password?

Solutions

Expert Solution

Generating a password with same characters is bit easy to crack, whereas generating a password containing alphabets, digits and symbols makes it difficult to crack it.

_________________________________________________________________________

a) Entropy of a password defines how much difficult it is to predict and crack the password.

    Here's the formula to calculate the Entropy,

  • Entropy (E) =|K| * log2(), where |K| is the length of the password and is the number of printable characters in the US keyboard.
  • We have |K| = 7 and = 94
  • Number of available characters ^ length of the password, gives the total possible combination of the password.
  • ^|K| = 94^7
  • 94^7 = 64,847,759,419,264 possible combinations of the password.
  • Entropy (E) = 7 * log2(94)
  • log2(94) = 6.554588852
  • Let's round off the value to one decimal place, therefore log2(94) = 6.5
  • 6.5 is the value of entropy per character
  • Now, Entropy (E) = 7 * 6.5 , where 7 is the length of the password
  • Entropy (E) = 45.5

_________________________________________________________________________

b) Hashing is a technique used to shorten the length of a data, it is similar to encryption but it is a one way encryption.

  • Hashing the password creates a new random string for that password, which can be used to store it in a memory.
  • If we create a username and password to signup into a system/website. a hash for our password will be created and it will be stored in the memory. Our actual password will not be stored in the memory.
  • Next time if we enter the password to login to a system, the system generates a hash for the password we have entered and the system checks the newly generated hash with the already stored hash in its memory.
  • If both the hashes successfully matches, then we gain access to the system, else we have to try again.
  • Hashing a password ensures the safety of the password, even if a attacker gets the hash, it is nearly difficult to get back the

Calculation the time taken to crack the password:

  • Number of available characters ^ length of the password, gives the total possible combination of the password.
  • 94^7 = 64,847,759,419,264 possible combinations of the password.
  • The attacker has to hash all these 64,847,759,419,264 possible combinations of the password to match with the hash value he already have with him.
  • He adds the seed to each possible combination of the password to get the hash.
  • The seed is a 'salt' which is added to the actual password to create the hash value.
  • As he can generate 1010 hashes per second, and we there is 64,847,759,419,264 combination of hashes to check with, it roughly takes long years.
  • 1010 = 10000000000
  • 10000000000 x 60(seconds) = 600000000000 generated hashes per minute
  • 600000000000 x 60(minutes) = 36,000,000,000,000 generated hashes per hour
  • 64,847,759,419,264 / 36,000,000,000,000 = 1 hr 48 minutes
  • It takes 1 hr and 48 minutes to find the password.

_________________________________________________________________________

We were unable to transcribe this image

We were unable to transcribe this image

We were unable to transcribe this image

We were unable to transcribe this image

We were unable to transcribe this image

We were unable to transcribe this image

We were unable to transcribe this image

We were unable to transcribe this image

We were unable to transcribe this image

We were unable to transcribe this image


Related Solutions

The Python lookNsayNth(), given below, is a generator function that generates the digits (as characters) of...
The Python lookNsayNth(), given below, is a generator function that generates the digits (as characters) of the “n-th” “look-and-say number”. E.g., 1113… generates the characters ‘1’, ‘1’, ‘1’, ‘3’, etc. Use this generator to print out the 1,000,000-th to 1,000,019-th digits of the 200th “look-and-say” number. Check: your number will start with 211121… (Keep in mind that the 1st digit has index 0 if the digits were put in an array). Note that the 200th “look-and-say” number has somewhere around...
A password is a string of ten characters, where each character is a lowercase letter, a...
A password is a string of ten characters, where each character is a lowercase letter, a digit, or one of the eight special characters !, @, #, $, %, &, (, and ). A password is called awesome, if it contains at least one digit or at least one special character. Determine the number of awesome passwords.
Using c++, write a program that reads a sequence of characters from the keyboard (one at...
Using c++, write a program that reads a sequence of characters from the keyboard (one at a time) and creates a string including the distinct characters entered and displays the string on the screen. The input terminates once the user enters a white-space character or the user has entered 50 distinct characters. Do not use C-Strings. 2. Use the following function to append character “ch” to the string “s”: s.push_back(ch); 3. Read the input characters one by one, i.e. do...
Write a C++ program to read characters from the keyboard until a '#' character is read....
Write a C++ program to read characters from the keyboard until a '#' character is read. Then the program will find and print the number of uppercase letters read from the keyboard.
at a certain company, password must be formed 3-5 characters long and composed of the 26...
at a certain company, password must be formed 3-5 characters long and composed of the 26 letters of the alphabet, 10 digits 0-9, and 14 symbols. A. how many passwords are possible if repetition is allowed? B. what is the probability that a password chosen has at least 1 repeated character.
A password is a sequence of five characters. Each character is one of twenty-six uppercase letters...
A password is a sequence of five characters. Each character is one of twenty-six uppercase letters (“A” through “Z”), one of ten digits (“0” through “9”), or one of five symbols (“+”, “-”, “!”, “<”, “>”). Count the number of possible passwords that can be created in each of the following scenarios. Consider each part of this questions separately. (a) There are no restrictions on how the characters are chosen. (b) A password must begin with a letter and end...
An online account password for a certain website consists of eight characters, where at least one...
An online account password for a certain website consists of eight characters, where at least one must be a digit (i.e. a number from 0-9). a. How many different passwords are possible if only lowercase letters and digits can be used? b. How many different passwords are possible if a user wants to include single capital letter somewhere in their password? c. If a computer program randomly generates eight characters (such that each could be either a digit or any...
Given the following information n= 5 Σ Xt = 30 Σ Yt = 172 Σ Yt...
Given the following information n= 5 Σ Xt = 30 Σ Yt = 172 Σ Yt Xt = 980 Σ X2t = 205 Σ Y2t = 5162 Find the least squares estimates of α and β from Yt = α + βXt + ut The sum of squared residuals is 45.2691. What does the SSR tell us in general? Find the unbiased estimate of the variance of ut. What does S2 tell us in general? Test H0: β = 0...
A student wants to create a password consisting of 7 characters. How many possible ways can...
A student wants to create a password consisting of 7 characters. How many possible ways can the student create the password if the first three characters are letters following by two digits and the last two characters can be letters or digits?
I have to write a random password generator in Python 3 and im having some trouble...
I have to write a random password generator in Python 3 and im having some trouble writing the code and i dont really know where to start. The prompt goes as such: The problem in this assignment is to write a Python program that uses functions to build (several options of) passwords for the user. More specifically, your program will do the following: 1. Prompt the user for the length of the password to be generated. Call this length lenP....
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT