[PR #3433] [MERGED] feat(sso): add configurable limits for SSO provider registration #4817

Closed
opened 2026-03-13 12:00:52 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/better-auth/better-auth/pull/3433
Author: @Kinfe123
Created: 7/17/2025
Status: Merged
Merged: 7/19/2025
Merged by: @Bekacru

Base: v1.3Head: feat/sso-configurable-provider-limit


📝 Commits (1)

  • adeeee8 feat: sso configurable provider limit

📊 Changes

4 files changed (+294 additions, -0 deletions)

View changed files

📝 docs/content/docs/plugins/sso.mdx (+5 -0)
📝 packages/sso/src/index.ts (+42 -0)
📝 packages/sso/src/oidc.test.ts (+101 -0)
📝 packages/sso/src/saml.test.ts (+146 -0)

📄 Description

Summary by cubic

Added a configurable limit for how many SSO providers a user can register, with the option to disable registration or set dynamic limits per user.

  • New Features
    • Added providersLimit option to the SSO plugin, supporting numbers or functions.
    • Blocked SSO provider registration if the user reaches their limit or if registration is disabled.
    • Updated documentation and added tests for these cases.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/better-auth/better-auth/pull/3433 **Author:** [@Kinfe123](https://github.com/Kinfe123) **Created:** 7/17/2025 **Status:** ✅ Merged **Merged:** 7/19/2025 **Merged by:** [@Bekacru](https://github.com/Bekacru) **Base:** `v1.3` ← **Head:** `feat/sso-configurable-provider-limit` --- ### 📝 Commits (1) - [`adeeee8`](https://github.com/better-auth/better-auth/commit/adeeee8b4ebdea1f95a336a1f5a40498b6d22ca0) feat: sso configurable provider limit ### 📊 Changes **4 files changed** (+294 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `docs/content/docs/plugins/sso.mdx` (+5 -0) 📝 `packages/sso/src/index.ts` (+42 -0) 📝 `packages/sso/src/oidc.test.ts` (+101 -0) 📝 `packages/sso/src/saml.test.ts` (+146 -0) </details> ### 📄 Description <!-- This is an auto-generated description by cubic. --> ## Summary by cubic Added a configurable limit for how many SSO providers a user can register, with the option to disable registration or set dynamic limits per user. - **New Features** - Added `providersLimit` option to the SSO plugin, supporting numbers or functions. - Blocked SSO provider registration if the user reaches their limit or if registration is disabled. - Updated documentation and added tests for these cases. <!-- End of auto-generated description by cubic. --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-03-13 12:00:52 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/better-auth#4817