- 配置AuthService使用OpenIddict reference tokens - 添加fengling-api客户端用于introspection验证 - 配置Console API通过OpenIddict验证reference tokens - 实现Tenant/Users/Roles/OAuthClients CRUD API - 添加GatewayController服务注册API - 重构Repository和Service层支持多租户 BREAKING CHANGE: API认证现在使用OpenIddict reference tokens
70 lines
1.8 KiB
C#
70 lines
1.8 KiB
C#
namespace Fengling.Console.Models.Dtos;
|
||
|
||
/// <summary>
|
||
/// OAuth客户端详细信息DTO
|
||
/// </summary>
|
||
public class OAuthClientDto
|
||
{
|
||
/// <summary>
|
||
/// 客户端唯一标识符
|
||
/// </summary>
|
||
public string Id { get; set; } = string.Empty;
|
||
|
||
/// <summary>
|
||
/// 客户端ID,用于OAuth授权流程中的标识
|
||
/// </summary>
|
||
public string ClientId { get; set; } = string.Empty;
|
||
|
||
/// <summary>
|
||
/// 客户端显示名称
|
||
/// </summary>
|
||
public string DisplayName { get; set; } = string.Empty;
|
||
|
||
/// <summary>
|
||
/// 客户端描述信息
|
||
/// </summary>
|
||
public string? Description { get; set; }
|
||
|
||
/// <summary>
|
||
/// 回调地址列表,用于OAuth授权回调
|
||
/// </summary>
|
||
public string[] RedirectUris { get; set; } = Array.Empty<string>();
|
||
|
||
/// <summary>
|
||
/// 注销回调地址列表
|
||
/// </summary>
|
||
public string[] PostLogoutRedirectUris { get; set; } = Array.Empty<string>();
|
||
|
||
/// <summary>
|
||
/// 授权范围列表
|
||
/// </summary>
|
||
public string[] Scopes { get; set; } = Array.Empty<string>();
|
||
|
||
/// <summary>
|
||
/// 授权类型列表
|
||
/// </summary>
|
||
public string[] GrantTypes { get; set; } = Array.Empty<string>();
|
||
|
||
/// <summary>
|
||
/// 客户端类型:public(公开客户端)或 confidential(机密客户端)
|
||
/// </summary>
|
||
public string? ClientType { get; set; }
|
||
|
||
/// <summary>
|
||
/// 授权同意类型:implicit、explicit或system
|
||
/// </summary>
|
||
public string? ConsentType { get; set; }
|
||
|
||
/// <summary>
|
||
/// 客户端状态:active、inactive或suspended
|
||
/// </summary>
|
||
public string Status { get; set; } = "active";
|
||
}
|
||
|
||
/// <summary>
|
||
/// OAuth客户端列表分页结果DTO
|
||
/// </summary>
|
||
public class OAuthClientListDto : PagedResultDto<OAuthClientDto>
|
||
{
|
||
}
|