Prove
Ask for fresh proof before sensitive actions.
Better Auth Zero Access · by Railman
Add step-up approval, zero-access vaults, or sealed 1:1 chat to a Better Auth app. Pick what you need and leave the rest.
Publishing as @railman · pre-1.0 · review before production use
What this is
Better Auth Zero Access adds step-up approval, browser-held encryption keys, and sealed messaging on top of Better Auth.
Built by Railman, the suite lets Elevate, Vault, and Chat solve different problems. Passkey and PRF anchor Vault and Chat; Elevate can stand alone.
Ask for fresh proof before sensitive actions.
Keep encryption keys in the browser, not on your server.
Store ciphertext and message envelopes without plaintext.
How the suite fits together
The suite is passkey-centered. Elevate is the independent path when password or TOTP step-up is all you need.
No passkey required@railman/auth-elevatePassword, TOTP, or optional passkey proof for short-lived approval.
Elevate quick start →enhancePasskey()Vault unlock produces the client-held material that anchors Chat.
Elevate
Elevate gives Better Auth apps a short, server-verified approval window for sensitive actions. It works without passkeys, PRF, a MEK, or zero-access storage.
Require fresh proof before ownership transfer, deletion, or security settings.
Put plan changes, payment methods, and invoices behind a short sudo window.
Re-authenticate before users enroll, rotate, or disable recovery methods.
Grant privileged tools for minutes instead of the full login session.
No vault key, PRF output, or plaintext enters this path.
Enough for account controls. Nothing here can open a vault.
loginFactors()+twoFactor()+elevate()Choose the proof
Start with password re-entry and TOTP. Add passkey step-up when the same WebAuthn credential should protect login and sudo.
passwordUse when password confirmation fits the action’s risk level.
TOTPVerify a fresh Better Auth two-factor code for stronger proof.
passkeyUse when the same WebAuthn credential should protect login and sudo.
Passkey
@railman/auth-zero-access-passkey freezes RP and origin options, requires user verification, and pairs login with the counter guard.
Ship the secure options together instead of rebuilding stock WebAuthn settings by hand.
Give Elevate the same controller when passkey step-up is enabled.
Use PRF helpers when Vault needs browser-held key material.
Vault and Chat keep secrets on the client side of TLS.
Elevate does not need this. Zero-access starts here.Vault
@railman/auth-zero-access stores wraps, recovery records, policy metadata, and optional relay data. It never receives vault secrets.
In your product
The server package stays blind. @railman/zero-vault handles create, unlock, reset, and re-enrollment in the browser.
Seal notes, files, credentials, and settings with a client-held MEK.
Use passkey PRF or a vault password in the browser. The server returns wraps, not keys.
Reset access with a recovery phrase and re-enroll daily methods without exposing the MEK.
Manage wrapped access methods while the server stores only metadata and ciphertext.
Chat
@railman/zero-e2e adds X3DH-style session setup and a Double Ratchet. It is not a group or multi-device messaging platform.
What Chat does
PasskeyPRFVault unlockIdentity seedZero-e2e consumes the seed; the Vault path performs the passkey and PRF ceremonies.
Session setupX3DH-style prekey exchange
Peer checkSafety-number fingerprint
After deliveryDouble Ratchet rotates message keys
Compare the paths
Elevate can run independently. Vault uses the passkey foundation, and Chat extends the unlocked Vault identity.
| Dimension | CoreElevate@railman/auth-elevate | CoreVault@railman/auth-zero-access | ExperimentalChat@railman/zero-e2e |
|---|---|---|---|
| Best for | Account, billing, recovery, and admin actions | Notes, files, credentials, and private settings | Sealed direct messages between two users |
| User proof | Password, passkey, or authenticator; server gates read the method | Passkey-centered; PRF, vault password, or recovery unlock | Identity seed supplied by the unlocked Vault |
| Client side | No encryption key required | MEK and plaintext stay in the browser | PRF path anchors identity; message keys rotate on the client |
| Server side | Verifies a fresh approval claim | Stores wraps, metadata, and ciphertext | Relays sealed envelopes and routing data |
| Guides | Read the Elevate guide → | Read the Vault guide → | Read the Chat guide → |
Also useful
Passkey hardens WebAuthn. Login Factors tracks how the session was established. Zero Vault is the browser UX for Vault.
@railman/auth-zero-access-passkeyHardens Better Auth passkeys and supplies the counter guard and PRF helpers.
Sessions@railman/auth-login-factorRecords how the user signed in and gates routes that need a stronger factor.
Browser vault@railman/zero-vaultHandles create, unlock, recovery, and re-enrollment in the browser.
Try it
Hosted data is disposable. Use a lab to see the flow before you wire it into your app.
Docs