/auth/webauthn/login/begin
生成登录挑战,返回给前端调用 navigator.credentials.get()
请求体
Schema: handler.beginLoginRequest
| 字段 | 类型 | 必填 | 示例 | 约束 | 描述 |
|---|---|---|---|---|---|
password |
string |
是 | length: 1–? |
响应
引用的 Schema
service-core/base/dto.SimpleResponse
| 字段 | 类型 | 必填 | 示例 | 约束 | 描述 |
|---|---|---|---|---|---|
code |
integer |
否 | |||
message |
string |
否 | |||
timestamp |
string |
否 |
service-identity/internal/handler/dto.WebAuthnCredentialDescriptor
| 字段 | 类型 | 必填 | 示例 | 约束 | 描述 |
|---|---|---|---|---|---|
id |
string |
否 | |||
transports |
array of string |
否 | |||
type |
string |
否 |
service-identity/internal/handler/dto.WebAuthnLoginOptionsResponse
| 字段 | 类型 | 必填 | 示例 | 约束 | 描述 |
|---|---|---|---|---|---|
allowCredentials |
array of 参见 |
否 | |||
challenge |
string |
否 | |||
rpId |
string |
否 | |||
timeout |
integer |
否 | |||
userVerification |
string |
否 |
service-identity/internal/handler/dto.WebAuthnLoginResponse
| 字段 | 类型 | 必填 | 示例 | 约束 | 描述 |
|---|---|---|---|---|---|
publicKey |
service-identity/internal/handler/dto.WebAuthnLoginOptionsResponse |
否 |
service-identity/internal/handler/dto.WebAuthnLoginResponseWrapper
| 字段 | 类型 | 必填 | 示例 | 约束 | 描述 |
|---|---|---|---|---|---|
code |
integer |
否 | |||
data |
service-identity/internal/handler/dto.WebAuthnLoginResponse |
否 | |||
message |
string |
否 | |||
timestamp |
string |
否 |