← ClaudeAtlas

padosoft-auth-hardeninglisted

Use this skill when building or reviewing anything to do with who a user is and how long they stay that way — login, registration, password reset or change, email change, invitations, sessions, API tokens, second factor, logout, remember-me, a captcha on a form. Also when the user reports credential stuffing, an account enumeration finding, a session that never expires, a password change that did not log other devices out, a lockout that never fires, or asks what a new application needs before it opens to the public. It gives the control, the reason it is shaped that way, and the ways each one is commonly present but ineffective. Do not use it for authorisation and ownership (padosoft-tenant-isolation) or for the whole security posture (padosoft-security-baseline).
padosoft/skills · ★ 1 · API & Backend · score 80
Install: claude install-skill padosoft/skills
# Authentication hardening The controls below are the ones that are typically *present and ineffective*: a limiter with the wrong key, a lockout event nothing emits, a session lifetime that is a sliding window, a revocation that covers one door out of three. **The rule: identity is a set of doors, and hardening means none of them disagrees with the others.** --- ## 1. Rate limiting needs two keys, not one ```text per address only → distributed credential stuffing walks through per account only → N accounts get swept in parallel from one machine both → the attack has to be both slow and narrow ``` - Key the per-account limit on a **hash of the normalised identifier**, never the address itself: a limiter backed by a shared cache otherwise stores your users' email addresses in plaintext, in a second system, for ever. - Put the client address **into** the per-account key as well, or an attacker can lock a real customer out of their own account at will. Denial of service against a named user is a cheap attack. - **Limit the reset and the contact forms too.** They send mail on somebody else's behalf. - **Check that a lockout actually emits an event.** Many frameworks only emit it from their own built-in throttling helper; a hand-rolled limiter raises nothing, so the detection rule that counts lockouts can never fire and nobody notices that nothing is noticing. ## 2. Nothing may enumerate accounts The response must be identical whether or not the acc