1.2 Quiz: Password Attacks | AP Cybersecurity
Password Attacks — Quiz
5 questions • Predict first • Instant per-question feedback
Which attack type is described, and why does the bank’s account lockout policy NOT prevent it?
The signal for credential stuffing is always prior breach data + a different target site. The attacker is not guessing — they are replaying. Lockout cannot stop an attack that sends exactly one correct attempt per account. Slash the trash: brute force would require many attempts per account; password spraying uses one shared common password across accounts (not unique pairs from a breach); dictionary attack uses a wordlist of probable guesses, not confirmed credentials.
A security auditor flags this implementation as flawed. Which of the following BEST identifies the weakness?
Two separate flaws exist here: (1) deterministic “salt” — the username is public and predictable, so an attacker who knows the username can precompute a targeted rainbow table for that user; and (2) fast algorithm — SHA-256 is optimized for speed, allowing billions of guesses per second offline. A proper implementation requires a randomly generated per-user salt (unpredictable, even if the attacker knows usernames) plus bcrypt/Argon2 (slow by design). MD5 (option C) is worse than SHA-256 for password storage, not better.
Which statement MOST accurately identifies the policy flaw and its security consequence?
NIST SP 800-63B counterintuitive facts are high-frequency exam targets: forced rotation reduces security rather than increasing it, because it drives predictable incremental patterns. The employees are not “failing to comply” — they are responding rationally to an unworkable policy. The correct approach is: no forced rotation unless compromised, minimum 15–16 character length, block known-breached passwords at creation, and support passphrases up to 64 characters.
A security engineer proposes the following changes to a company’s authentication system after a breach:
II. Add a mandatory 90-day password rotation policy so that even if a password is cracked from the stolen hash database, the cracked credential will only be valid for a maximum of 90 days.
III. Deploy per-user randomly generated salts so that two users with identical passwords produce completely different stored hashes, defeating precomputed lookup table attacks.
Which statements describe changes that would genuinely improve resistance to the attacks they claim to address?
I and III are both genuine, targeted improvements: bcrypt directly defeats offline brute force by making each hash guess expensive; random salts directly defeat precomputed rainbow tables by ensuring every hash is unique. Statement II sounds reasonable but contradicts NIST — forced rotation causes users to cycle through predictable patterns, producing passwords like “Company60!” that an attacker who recovered “Company59!” could trivially guess. The validity window argument fails in practice because the pattern is crackable before expiration.
• Passwords are stored as bcrypt hashes with unique per-user salts (cost factor 10)
• Employee accounts have no MFA
• The default onboarding password is “Welcome2026!” and 23% of accounts have never changed it
• 61% of employees reuse their hospital password for personal email, based on a voluntary survey
• Account lockout triggers after 8 failed attempts per account
The tester has access to: (a) a LinkedIn scrape of all 1,400 employee emails, and (b) 400 million credential pairs from the 2024 breach of a national pharmacy chain.
Which of the following MOST accurately identifies the attacks available to the tester AND the single control with the broadest impact across all viable attacks?
Slash the trash systematically: (A) Rainbow table is defeated by the bcrypt + salt already in place — eliminate. (B) Brute force against bcrypt at cost factor 10 is impractical; and lowering lockout to 3 would not stop spraying at 1 attempt/account — eliminate. (C) Deploying bcrypt is already done; it does not stop spraying or stuffing, which never touch the hash database — eliminate. (D) is correct: the LinkedIn email list enables password spraying using the default “Welcome2026!” credential (1 attempt per account, 23% success rate = ~322 accounts). The pharmacy breach enables credential stuffing (61% reuse = ~854 employees at risk). MFA stops both: even with a valid or default password, the attacker cannot authenticate past the second factor.
Get in Touch
Whether you're a student, parent, or teacher — I'd love to hear from you.
Just want free AP CS resources?
Enter your email below and check the subscribe box — no message needed. Students get daily practice questions and study tips. Teachers get curriculum resources and teaching strategies.
Message Sent!
Thanks for reaching out. I'll get back to you within 24 hours.
tanner@apcsexamprep.com
Courses
AP CSA, CSP, & Cybersecurity
Response Time
Within 24 hours
Prefer email? Reach me directly at tanner@apcsexamprep.com