UNDERSTAND
Bring these concepts with you
BUILD
Your implementation
- Implement detectCredentialAnomalies(events, { failureThreshold, windowMs }).
- Group events per user chronologically and flag >= failureThreshold failures followed by a success from a different sourceIp within windowMs.
- Include status: 'needs-investigation' and benignAlternatives rather than claiming confirmed compromise.
export function detectCredentialAnomalies(events, { failureThreshold = 3, windowMs = 600000 } = {}) {
// Flag failure bursts followed by a new-IP success as leads with benign alternatives.
}Need a hint?
- Sort per-user events by Date.parse(ts) before running the sliding time window.
- An IP address change alone could be a VPN disconnect or cellular roam.
Saved on this device · 0 / 6000 · Do not include passwords or private data.
VERIFY
Acceptance checks
From the folder containing your downloaded files, run:
node checks.mjs ./starter.mjs 3This runs checks up to this step. Earlier steps must work first. Mark each result only after checking your implementation; the website does not run or grade it.
Record your attempt to enable the checklist and reference comparison.
Compare with the reference
Attempt the step first, then compare decisions and behavior. There can be more than one correct implementation.
EXPLAIN
Your interviewer asks
Why does a login from a new IP after three failures not prove account takeover by itself?
Say your answer aloud, then record the trade-offs and evidence in your notes above.
LOCAL VOICE REHEARSAL
Rehearse your step walkthrough aloud
00:00/ 02:00