Repository navigation
Releases
@checodo/better-auth-normalize@0.2.0
Minor Changes
-
2e6b989: First release: email and phone number normalization.
emailNormalization()(/email): stores the address an email reaches inuser.normalizedEmail(unique): trimmed, lowercased, and the tags (and Gmail's dots) that Gmail, Outlook, iCloud, Proton, and Fastmail ignore removed, or+tagsat every domain withsubaddressing: "all". A second account for the same inbox is refused on every way of creating a user or changing an email, with better-auth's own answer for an existing email (USER_ALREADY_EXISTS_USE_ANOTHER_EMAIL, or, where better-auth hides existing users, its success-shaped response andonExistingUserSignUp).allowNormalizedSignInlets people sign in with any form of their address.backfillNormalizedEmailsfills existing users a batch at a time and reports inboxes with two accounts. With the audit log, refusals are recorded asnormalize.email-alias-refused.phoneNormalization()(/phone): stores every number of better-auth'sphoneNumberplugin in E.164 and refuses invalid ones (INVALID_PHONE_NUMBER), withdefaultCountryfor national numbers.
@checodo/better-auth-blocklist@0.4.0
Minor Changes
- 2e6b989: Privacy relays (Firefox Relay, DuckDuckGo, SimpleLogin, addy.io, Proton Pass) are no longer treated as disposable:
disposableEmailDomainsnever contains them (it containedrelay.firefox.com). The newprivacyRelayDomainslist (/listsand/lists/privacy-relay-domains) lets apps that want one account per person block them too. The lists are refreshed from their sources.
@checodo/better-auth-waitlist@0.5.0
Minor Changes
- 4d87d69: Deleting a user now deletes their waitlist entry, which holds their email address. Before, the entry stayed (marked
registered) until an admin deleted it orretentionremoved it. If you need to keep it, read it in auser.delete.beforedatabase hook first.
@checodo/better-auth-security-alerts@0.2.2
Patch Changes
- 4d87d69: Forgetting a deleted user's devices now shares its code with the other plugins. A failure is logged as
[security-alerts] failed to erase the devices of a deleted user; the behavior is unchanged.
@checodo/better-auth-security-alerts@0.2.1
Patch Changes
- 6fb82ef: With
newDevice.maxDevicesabove 100, every known device is now read: the device check andlistDevicessaw at most 100 of a user's devices.
@checodo/better-auth-referral@0.5.0
Minor Changes
- 4d87d69: Deleting a user now deletes their referral code, the referrals they made or that brought them, and those referrals' steps and places on every adapter. Before, this relied on foreign keys, so with MongoDB, SQLite without
PRAGMA foreign_keys, or a custom adapter the rows stayed. Nothing changes where foreign keys already deleted them.
@checodo/better-auth-referral@0.4.2
Patch Changes
- 6fb82ef: Referral lists now show every completed step: with more than 100 steps on one page of referrals, the rest were left out.
@checodo/better-auth-blocklist@0.3.2
Patch Changes
- 6fb82ef: Security fix: rules stored in the database are now all checked. Only the first 100 rules of each target were read, because better-auth's adapters return at most 100 rows unless told otherwise, so with more than 100 stored rules for a target (emails, usernames, IP addresses...) the newer ones were silently ignored.
listRulesnow also returns every rule.
@checodo/better-auth-audit-log@0.3.1
Patch Changes
- 6fb82ef:
verifyAuditChainno longer reports falsemissing-eventproblems once the chain has more than 100 links. It read the events of up to 500 links at a time, but got at most 100 back.
@checodo/better-auth-audit-log@0.3.0
Minor Changes
-
4dbc521: Send audit events to more places with the new
destinationsoption: a SIEM, a log service, or a webhook, each with its own event filter,transform, and batching. Sending runs in the background and is best effort; a failing or slow destination never fails the request.auth.api.flushAuditDestinations()sends waiting batches before shutdown.The new
@checodo/better-auth-audit-log/destinationsentry point hashttpDestination(JSON or NDJSON, optional Standard Webhooks signature, never follows redirects) andconsoleDestination.A custom
storagenow only needswrite: withoutread,listEventsanswersREAD_NOT_SUPPORTED(501); withoutdeleteOlderThan,retentionis refused at startup anddeleteExpiredAuditEventsanswersDELETE_NOT_SUPPORTED(501). Existing storages keep working. -
46134cf: Export audit events and verify the hash chain over HTTP, for admins.
GET /audit-log/export(auth.api.exportAuditEvents): NDJSON or CSV, newest first, with the same filters aslistEvents. Up to 10,000 events per request; thex-next-cursorresponse header continues the export, unaffected by new events. CSV cells that a spreadsheet would run as a formula get a leading'.POST /audit-log/verify-chain(auth.api.verifyAuditChain): now also reachable over HTTP, at most 10,000 links per request. The newafterSequenceandlimitoptions check the chain in parts; the result's newnextSequencecontinues the check.- Both are admins only over HTTP (new error codes
YOU_ARE_NOT_ALLOWED_TO_EXPORT_EVENTS,YOU_ARE_NOT_ALLOWED_TO_VERIFY_THE_CHAIN,INVALID_CURSOR) and rate limited to 10 requests a minute. Calls from server code without headers need no session, as before.