Open
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
94b22b5 to
778f119
Compare
778f119 to
303a905
Compare
303a905 to
353a3f0
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
~1.5.6→~1.6.0Release Notes
better-auth/better-auth (better-auth)
v1.6.2Compare Source
Patch Changes
#8949
9deb793Thanks @ping-maxwell! - security: verify OAuth state parameter against cookie-stored nonce to prevent CSRF on cookie-backed flows#8983
2cbcb9bThanks @jaydeep-pipaliya! - fix(oauth2): prevent cross-provider account collision in link-social callbackThe link-social callback used
findAccount(accountId)which matched by account ID across all providers. When two providers return the same numeric ID (e.g. both Google and GitHub assign99999), the lookup could match the wrong provider's account, causing a spuriousaccount_already_linked_to_different_usererror or silently updating the wrong account's tokens.Replaced with
findAccountByProviderId(accountId, providerId)to scope the lookup to the correct provider, matching the pattern already used in the generic OAuth plugin.#9059
b20fa42Thanks @gustavovalverde! - fix(next-js): replace cookie probe with header-based RSC detection innextCookies()to prevent infinite router refresh loops and eliminate leaked__better-auth-cookie-storecookie. Also fix two-factor enrollment flows to set the new session cookie before deleting the old session.#9058
608d8c3Thanks @gustavovalverde! - fix(sso): include RelayState in signed SAML AuthnRequests per SAML 2.0 Bindings §3.4.4.1authnRequestsSigned: truewithout a private key now throws instead of silently sending unsigned requests.#8772
8409843Thanks @aarmful! - feat(two-factor): include enabled 2fa methods in sign-in redirect responseThe 2FA sign-in redirect now returns
twoFactorMethods(e.g.["totp", "otp"]) so frontends can render the correct verification UI without guessing. TheonTwoFactorRedirectclient callback receivestwoFactorMethodsas a context parameter.otpOptions.sendOTPis configured.#8711
e78a7b1Thanks @aarmful! - fix(two-factor): prevent unverified TOTP enrollment from gating sign-inAdds a
verifiedboolean column to thetwoFactortable that tracks whether a TOTP secret has been confirmed by the user.enableTwoFactorcreates the row withverified: false. The row is promoted toverified: trueonly afterverifyTOTPsucceeds with a valid code.enableTwoFactorwhen TOTP is already verified): the new row preservesverified: true, so the user is never locked out of sign-in while rotating their TOTP secret.verifyTOTPrejects rows whereverified === false, preventing abandoned enrollments from blocking authentication. Backup codes and OTP are unaffected and work as fallbacks during unfinished enrollment.Migration: The new column defaults to
true, so existingtwoFactorrows are treated as verified. No data migration is required.skipVerificationOnEnable: trueis also unaffected — the row is created asverified: truein that mode.Updated dependencies []:
v1.6.1Compare Source
Patch Changes
#9023
2e537dfThanks @jonathansamines! - Update endpoint instrumentation to always use endpoint routes#8902
f61ad1cThanks @ping-maxwell! - useINVALID_PASSWORDfor allcheckPasswordfailures#9017
7495830Thanks @bytaesu! - restore getSession accessibility in generic Auth contextUpdated dependencies []:
v1.6.0Compare Source
Minor Changes
#8836
5dd9e44Thanks @gustavovalverde! - Add case-insensitive query support for database adapters#8836
5dd9e44Thanks @gustavovalverde! - Add optional version field to the plugin interface and expose version from all built-in pluginsPatch Changes
#8985
dd537cbThanks @gustavovalverde! - deprecateoidc-providerplugin in favor of@better-auth/oauth-providerThe
oidc-providerplugin now emits a one-time runtime deprecation warning when instantiated and is marked as@deprecatedin TypeScript. It will be removed in the next major version. Migrate to@better-auth/oauth-provider.#8843
bd9bd58Thanks @gustavovalverde! - enforce role-based authorization on SCIM management endpoints and normalize passkey ownership checks via shared authorization middleware#8836
5dd9e44Thanks @gustavovalverde! - Return additional user fields and session data from the magic-link verify endpoint#8836
5dd9e44Thanks @gustavovalverde! - Allow passwordless users to enable, disable, and manage two-factor authentication#8836
5dd9e44Thanks @gustavovalverde! - Prevent updateUser from overwriting unrelated username or displayUsername fields#8836
5dd9e44Thanks @gustavovalverde! - Use non-blocking scrypt for password hashing to avoid blocking the event loop#8836
5dd9e44Thanks @gustavovalverde! - Enforce username uniqueness when updating a user profile#8836
5dd9e44Thanks @gustavovalverde! - Align session fresh age calculation with creation time instead of update time#8836
5dd9e44Thanks @gustavovalverde! - Compare account cookie by provider accountId instead of internal id#8836
5dd9e44Thanks @gustavovalverde! - Trigger session signal after requesting email change in email-otp plugin#8836
5dd9e44Thanks @gustavovalverde! - Rethrow sendOTP failures in phone-number plugin instead of silently swallowing them#8836
5dd9e44Thanks @gustavovalverde! - Read OAuth proxy callback parameters from request body when using form_post response mode#8980
469eee6Thanks @bytaesu! - fix oauth state double-hashing when verification storeIdentifier is set to hashed#8981
560230fThanks @bytaesu! - Preventanyfrom collapsingauth.$Inferandauth.$ERROR_CODES. Preserve client query typing when body isany.Updated dependencies [
5dd9e44,5dd9e44,5dd9e44]:Configuration
📅 Schedule: (UTC)
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.