bastion

Password Security and Management

Build this skill

Choose long, unique passwords or random passphrases, explain why reuse turns one leak into many break-ins, and manage them with a password manager.

Why "Tulsi@123" only looks strong

Sameer Joshi in accounts uses the password Tulsi@123 for his work email, for MedLedger and, as it happens, for his UPI app and a cricket quiz website. It ticks every box on the usual form: a capital letter, a symbol, some numbers. Yet it is one of the first things an attacker would try against a Tulsi Health account, because it is the company name followed by the most common ending in the world. A strong password is not one that satisfies a form. It is one that would take an attacker an impossibly long time to guess, and that is used in exactly one place.

How attackers actually guess

When you create a password, a well-built system does not store the password itself. It stores a scrambled fingerprint of it, called a hash, and when you log in it scrambles what you typed and compares the two fingerprints. Guessing can happen in two places. At a login page, guessing is slow: the page can lock the account after a few wrong tries or make each try wait. But when a company's whole list of stored fingerprints is stolen, the attacker can guess on their own computers, scrambling each guess and comparing it, with no lockout at all. A single fast computer can try around a billion guesses a second against a list stored carelessly.

Attackers also do not guess at random. They start with lists of passwords leaked from earlier breaches, then common words, names, cities, cricketers and years, and then the usual tricks people use to satisfy a form: a capital first letter, @ in place of a, 123 or ! at the end. Tulsi@123 falls in the first second of that search, however many symbols it contains. The maths of long random passwords only protects you if your password is genuinely unpredictable.

Length beats cleverness

For a password chosen at random, the number of possibilities is the number of characters to choose from, multiplied by itself once for every character in the password. A suitcase number lock shows the idea. Three dials of ten digits give 1,000 combinations; a fourth dial makes it 10,000. Every extra dial multiplies the work by ten, while swapping digits for something fancier on the same three dials would change much less. Passwords behave the same way: each extra character multiplies the guessing time by the size of the character set, so adding length helps far more than adding a symbol.

Tulsi@123seconds: a known pattern8 small letters3.5 minutes8 of any key77 days4 random words42 days12 small letters3 years5 random words900 years16 small letters1.4 million yearsTime to try every possibility at a billion guesses a second (each step of thescale is ten times longer)

Sixteen ordinary small letters beat eight characters of every kind by a huge margin. A pattern-based password is found almost at once whatever its length, because attackers try patterns first.

These numbers are a cautious worst case. Services that store passwords properly use deliberately slow scrambling, which can cut an attacker's speed by thousands of times. You cannot check how a website stores your password, though, so it is wise to choose one that would survive even the careless case. A strong password therefore has three properties: it is long, it is unpredictable (chosen at random, not from your life), and it is unique to one account.

Build some passwords yourself below and see how long a stolen-list attacker would need. Then try the mission, which allows only small letters, so the only tool left to you is length.

Passphrases: long and easy to remember

A long random string of letters is hard to remember. A passphrase solves this by using several random words instead of random characters, such as mango tractor velvet ladder. Each word is like one dial on the suitcase lock, except that the dial has thousands of positions instead of ten. The words must be chosen at random, by rolling dice against a word list or letting a password manager pick them. A line from a film song or a cricket commentary is a famous phrase, and attackers try famous phrases.

The short program below counts how many passphrases are possible when words are picked from a common list of 7,776 words. You can press Run without knowing any Python; then change the number of words on the line marked in a comment and run it again.

python · runs in your browser

Expected output:

text
Possible passphrases: 3,656,158,440,062,976
Days to try them all: 42
Years to try them all: 0.1
Line What it does
words_in_list = 7776 Stores the size of the word list. The phrase is built from these words.
words_in_phrase = 4 How many random words are in the phrase. This is the one value to change.
words_in_list ** words_in_phrase ** means "to the power of": 7,776 × 7,776 × 7,776 × 7,776, one multiplication for each word.
f"{combinations:,}" Prints the big number with commas so you can read it.
1_000_000_000 One billion guesses a second. Python lets you write underscores to make big numbers readable.
seconds / 86400 There are 86,400 seconds in a day, so this turns seconds into days.

Four random words take about six weeks to exhaust at a billion guesses a second, which is fine for most accounts but thin for your most important password. Five words push the time past 900 years, so use five or six for anything that guards other passwords.

Reuse: one leak, many break-ins

The biggest password danger is not weak passwords but password reuse, using the same password on several sites. Websites are breached all the time, and the leaked lists of email addresses and passwords are sold and shared. Attackers then feed each email and password pair into the login pages of email services, shops, banks and workplaces, a technique called credential stuffing. Sameer's cricket quiz site had poor security and leaked its list; within days, someone was trying sameer.joshi@tulsihealth.in with Tulsi@123 on the company's mail service.

One password everywhere Sameer uses Tulsi@123 for all of these Cricket quiz site ✕ leaked its list Tulsi@123 Work email open ✕ MedLedger open ✕ UPI app open ✕ Shopping open ✕ One leak on a site he barely uses opens every account he cares about. A password manager one master password unlocks a unique one per site Master password Work email q7#Lm2vR… MedLedger Zt9!wPe4… UPI app fH3$kd8Q… Cricket quiz ✕ Xb5@nt1J… ✓ The leak exposes one password that works nowhere else Reuse turns one small leak into many break-ins. Unique passwords keep each leak small.

With one password everywhere, a leak at the least important site opens the most important ones. With a different password for each site, a leak stays a small problem.

Site leaksquiz site breachedList sharedemails + passwordssoldTried elsewheremail, banks, shopsautomatedAccount opensame password worksif reusedA unique password breaks the chain at the last step

You cannot stop other websites from being breached. You can make sure a password leaked from one of them opens nothing else.

Password managers make unique passwords practical

Nobody can remember sixty unique random passwords. A password manager is an app that creates a long random password for every site, stores them all in an encrypted vault (scrambled so that only the right key can read it), and fills them in for you. You remember one strong master password, ideally a five or six word passphrase, and protect the vault with a second check such as a code on your phone. Good managers also refuse to fill a password on a lookalike site such as tulsihea1th.in, because the address does not match, which quietly protects you from fake login pages.

People worry that a manager puts all their eggs in one basket. It does, but it is a very strong basket compared with the alternative of reused or written-down passwords. A reputable manager, a strong master passphrase and a second login step make the vault far safer than a memory full of variations on Tulsi@123. The password manager built into your phone or browser is a reasonable choice for personal accounts; at work, use the one your IT team provides.

Habits that keep passwords safe

A few habits matter as much as the password itself. Never share a password, even with IT: Neha will never ask for yours, and anyone who does is a warning sign. Never write one on a note stuck to a counter laptop. Change a password when you hear it may have leaked, rather than on a fixed calendar; current guidance has moved away from forcing changes every few months, because people respond by making small predictable edits. Turn on a second login step wherever it is offered.

Work through the decisions below as Riya, who has just installed a password manager and is cleaning up her accounts. Choose the safest practical move each time.

Follow your curiosity.

↑ ↓ to explore · Enter to open · Escape to close