Skip to content

Sso password availability - #7389

Open
shortlight5980 wants to merge 2 commits into
labring:mainfrom
shortlight5980:sso-password-availability
Open

shortlight5980 wants to merge 2 commits into
labring:mainfrom
shortlight5980:sso-password-availability

Conversation

@shortlight5980

Copy link
Copy Markdown
Collaborator
  1. sso增加禁止账号密码登录功能
  2. admin管理端用户配置页面重构

@github-actions

github-actions Bot commented Jul 27, 2026

Copy link
Copy Markdown

Coverage Report

Status Category Percentage Covered / Total
🔵 Lines 42.44% 4571 / 10769
🔵 Statements 42.26% 4838 / 11446
🔵 Functions 35.88% 909 / 2533
🔵 Branches 37.4% 2489 / 6655
File CoverageNo changed files found.
Generated in workflow #3573 for commit 6da9a60 by the Vitest Coverage Report Action

@github-actions

github-actions Bot commented Jul 27, 2026

Copy link
Copy Markdown

Docs preview deployed

🔗 👀 Click here to visit preview

ghcr.io/labring/fastgpt-docs-pr:6da9a6047ee9e876a38f79eb17081f5c40fd5845

🕒 Time: 2026-09-20 17:26:10 (UTC+8)

@github-actions

github-actions Bot commented Jul 27, 2026

Copy link
Copy Markdown

Admin Preview Image Ready!

ghcr.io/labring/fastgpt-pr:admin_6da9a6047ee9e876a38f79eb17081f5c40fd5845

🕒 Time: 2026-09-20 17:28:53 (UTC+8)

@github-actions

github-actions Bot commented Jul 27, 2026

Copy link
Copy Markdown

Build and publish successful - Preview fastgpt Image:

ghcr.io/labring/fastgpt-pr:fastgpt_6da9a6047ee9e876a38f79eb17081f5c40fd5845

🕒 Time: 2026-09-20 17:29:53 (UTC+8)

@shortlight5980
shortlight5980 force-pushed the sso-password-availability branch from 2337dd2 to d74b86e Compare August 14, 2026 03:39
@cla-assistant

cla-assistant Bot commented Aug 14, 2026

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


dry seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@cla-assistant

cla-assistant Bot commented Aug 14, 2026

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
1 out of 2 committers have signed the CLA.

✅ shortlight5980
❌ Codex


Codex seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@shortlight5980
shortlight5980 force-pushed the sso-password-availability branch 2 times, most recently from 39c9a61 to 660f599 Compare August 17, 2026 02:03
@github-actions

Copy link
Copy Markdown

✅ Docs preview image built successfully for 660f599e45041f3cf5e41312f88594d2a37ef975.

Automatic publishing is disabled for this PR. A maintainer can comment:

/preview push

to publish the image from this exact build.

@github-actions

Copy link
Copy Markdown

✅ Preview images built successfully for 660f599e45041f3cf5e41312f88594d2a37ef975.

Automatic publishing is disabled for this PR. A maintainer can comment:

/preview push

to publish the images from this exact build.

@shortlight5980
shortlight5980 force-pushed the sso-password-availability branch from 660f599 to a298332 Compare August 17, 2026 03:05
@shortlight5980
shortlight5980 force-pushed the sso-password-availability branch 3 times, most recently from 75a27b4 to 5c33573 Compare September 20, 2026 04:09
dry added 2 commits September 20, 2026 17:20
SSO 用户禁用本地密码:
- FeConfigs.sso 新增 disablePasswordForSsoUsers,与 sso.url 一起决定当前运行
  环境是否禁用 SSO 用户的平台密码
- 密码服务提供 isSsoPasswordDisabled / isSsoUserByUsername /
  getUserPasswordAvailability / assertUserPasswordAvailable,账号分类规则复用
  resolveAccountKindByUsername,登录、修改密码、重置密码在受限 SSO 用户上直接
  拒绝
- 新增 UserErrEnum.ssoPasswordUnavailable 与 verificationChannelUnavailable
  及中/英/繁三语文案
- UserType 增加 passwordAvailable,getUserDetail 一并下发;账号信息页与过期
  密码弹窗据此隐藏密码入口
- admin 用户列表 schema 暴露 isSsoUser,供管理端置灰密码相关操作

登录方式重构:
- 新增登录方式选择页、LoginMethodSelection 与 useLoginMethods,按运维配置计算
  可见登录方式与自动跳转 Provider;SSO 禁用密码时首个可见状态为方式选择页
- 下线 fastlogin 免登页面

管理端配置:
- TEAM_MODE 改为选填,只能由环境变量权威配置,缺省回落 single,中英文档同步
  补充升级提醒

对应 pro 改动:admin 用户配置页按渠道能力模型重构、验证码渠道按能力拒绝、
fastLogin 接口下线。
- 替换AuthChannelValidationConfig类型为AuthChannelConfigInput,支持wecom渠道
- 为各认证渠道添加完整的配置验证函数(isEmailAuthConfigComplete等)
- 更新getAuthChannelConfigValidationError使用统一的验证逻辑和中文错误消息
- 移除对许可证和环境变量的运行时依赖,统一使用配置完整性判定渠道能力
- 在用户管理界面中添加SSO密码策略控制,禁用受限制用户的密码输入
- 调整团队模式配置逻辑,移除环境变量对数据库值的覆盖机制
- 删除过期通知模板相关代码(EXPIRED邮件、短信和站内信模板)
- 简化系统初始化流程,配置初始化失败时记录错误而非抛出异常
@shortlight5980
shortlight5980 force-pushed the sso-password-availability branch from 5c33573 to 6da9a60 Compare September 20, 2026 09:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants