Harmony Virtual Lab

Digital Technologies · Cybersecurity and online safety

How strong is a password?

Test made-up passwords, measure their strength in bits and see how long an attacker would need to guess them.

Start this experimentAll Digital Technologies experiments

Aim

To investigate how the length and variety of characters in a password affect how hard it is to guess.

Apparatus

  • This password analyser
  • A list of made-up passwords to test

Theory

An attacker’s computer can try billions of guesses each second. The number of possible passwords is (size of character set)length. Strength is measured in bits of entropy:

bits = length × log₂(character set size)

Every extra bit doubles the work for the attacker. Common words, names, football clubs and patterns such as 123456 are tried first, so they are weak whatever their length.

Procedure

  1. Type a made-up password. Do not use a real password of yours.
  2. Read its length, character types, entropy and estimated time to crack, then record it.
  3. Test a short password, then make it longer one character at a time.
  4. Compare a password using only lower-case letters with one that mixes letters, digits and symbols.
  5. Try a common word such as “password” or “chelsea” and see what happens.

Precautions

Never type or share a password you actually use. This page works offline and sends nothing anywhere, but the habit matters.

What you do in the virtual lab

Set up the apparatus on screen, take readings and record them in a table (Password tested; Length; Character types; Entropy (bits); Time to crack; Rating), then plot Entropy (bits) against Password length (characters) and read the result from the graph. Simulated instruments give slightly different readings each time, as real ones do. Finish with a short quiz; every answer is explained.

Teachers can set the experiment for a class, see each student’s results and use it as a WAEC- or NECO-style practical paper in exam practice.

Practice questions

  1. Which password is the strongest?

    1. chelsea
    2. 12345678
    3. river-Mango-47-kite!
    4. Tunde2010
    Show the answer

    C. river-Mango-47-kite! It is long, mixes character types and is not a single common word, name or pattern.

  2. Adding one more character to a password

    1. multiplies the number of possible passwords
    2. makes no difference
    3. halves its strength
    4. only matters if it is a symbol
    Show the answer

    A. multiplies the number of possible passwords Each extra character multiplies the possibilities by the size of the character set.

  3. Why is “password1” weak even though it has letters and a digit?

    1. It is too long
    2. It has no capital letter
    3. Digits are not allowed
    4. It is on every attacker’s list of common passwords
    Show the answer

    D. It is on every attacker’s list of common passwords Attackers try known common passwords before anything else.

Do the experiment and the full quiz

Related Digital Technologies experiments

  • Logic gates and truth tablesDigital Technologies · SSS 1 – SSS 2Switch the inputs of AND, OR, NOT, NAND, NOR and XOR gates and build each truth table.
  • Binary, octal and hexadecimalDigital Technologies · JSS 2 – SSS 1Flip eight bit-switches to see how computers store numbers, then hit target values in binary.
  • Programming a robot: sequence and loopsDigital Technologies · JSS 1 – SSS 1Write a program of moves and turns to steer a robot to its goal, then shorten it with a loop.
  • Spreadsheet formulas and functionsDigital Technologies · JSS 2 – SSS 2Use cell references, SUM, AVERAGE, MAX and IF to complete a shop sales record and a class result sheet.
  • Coding in PythonDigital Technologies · SSS 1 – SSS 3Write real Python – print, variables, loops and if statements – and have each program checked automatically.
  • Train a simple AIDigital Technologies · JSS 3 – SSS 3Teach a computer to tell ripe plantain from unripe by giving it labelled examples, then test how accurate it is.