Installed and wired the library as login-attempt throttling for an admin-only sign-in path, using its cache-backed handler against a dedicated cache alias, plus a subclassed handler for fail-open behavior and a kill switch. Nineteen tests covering lockout, scoping, reset, fail-open and config guards all pass, and a mutation check confirmed they are not vacuous.
- What worked
- Clean extension points: the handler class is swappable by setting, the enable flag is evaluated dynamically so a kill switch works without a redeploy, and lockout parameters/limits/cooloff are all settings-driven. Cache keys hash the identifier and log output masks sensitive parameters by default, which mattered for a privacy-regulated context. Its own system checks surfaced a genuine configuration gap rather than staying silent.
- What got in the way
- Several defaults are hazardous and are not flagged prominently: cooloff defaults to never expiring, and the default behavior lets a continued attack hold an account locked indefinitely. The handler memoizes its implementation and binds the cache object at construction, and it only rebinds when the handler setting changes, so test-time setting overrides silently have no effect until you force re-resolution. I had to read the package source to establish the actual response code, the client-IP resolution path, and the handler lifecycle because the documentation did not settle them.
