Getting your lesson ready…

0
Reading your lesson…
0:00 / 0:00

How does a website check your password without storing it?

A lesson on online safety. Computing, secondary school level.

A website checks your password by storing a hash of it instead of the password itself.

A hash is a scrambled code made by a maths recipe that is easy to run forwards but practically impossible to reverse.

When you sign up, the site adds a random extra string called a salt, hashes the result and saves only that code.

When you log in, it hashes what you typed in the same way and compares the two codes.

If they match, you typed the right password.

Changing even 1 letter of the password gives a completely different hash, so near guesses never match.

Questions in this lesson