Search by

componenta / auth-recovery-code

Shelamkoff

Single-use recovery codes for Componenta Auth 3

Package info

github.com/componenta/auth-recovery-code

pkg:composer/componenta/auth-recovery-code

Statistics

Installs: 3

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

v2.0.0 2026-10-10 21:22 UTC

This package is auto-updated.

Last update: 2026-10-10 21:22:42 UTC


README

Single-use recovery codes for Componenta Auth 3.

Each recovery code contains 128 bits of CSPRNG entropy. Raw codes are returned only when a new batch is generated; the database stores only domain-separated SHA-256 hashes. Regenerating a batch invalidates all previous codes.

Recovery-code authentication is explicitly marked as recovery evidence and does not claim phishing resistance.

Version 2 compatibility

Version 2.0.0 requires componenta/auth-session-http ^2.0.1 and the CSRF v3 browser security model. Unsafe protected requests require valid Origin/Referer evidence and a valid CSRF token; an omitted origin must never be accepted by default. Auth's session-issuance contract remains unchanged.

See CHANGELOG.md for migration details and the verified security-admission tests.