Skip to content

Commit ebe8d6c

Browse files
authored
docs: add missing parameters back to openid-connect plugin docs (#12673)
1 parent 1af6ec4 commit ebe8d6c

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

docs/en/latest/plugins/openid-connect.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,12 @@ The `openid-connect` Plugin supports the integration with [OpenID Connect (OIDC)
9999
| introspection_interval | integer | False | 0 | | TTL of the cached and introspected access token in seconds. The default value is 0, which means this option is not used and the Plugin defaults to use the TTL passed by expiry claim defined in `introspection_expiry_claim`. If `introspection_interval` is larger than 0 and less than the TTL passed by expiry claim defined in `introspection_expiry_claim`, use `introspection_interval`. |
100100
| introspection_expiry_claim | string | False | exp | | Name of the expiry claim, which controls the TTL of the cached and introspected access token. |
101101
| introspection_addon_headers | array[string] | False | | | Used to append additional header values to the introspection HTTP request. If the specified header does not exist in origin request, value will not be appended. |
102-
| claim_validator.issuer.valid_issuers | string[] | False | | | Whitelist the vetted issuers of the jwt. When not passed by the user, the issuer returned by discovery endpoint will be used. In case both are missing, the issuer will not be validated. |
102+
| claim_validator | object | False | | | JWT claim validation configurations. |
103+
| claim_validator.issuer.valid_issuers | array[string] | False | | | An array of trusted JWT issuers. If unconfigured, the issuer returned by discovery endpoint will be used. If both are unavailable, the issuer will not be validated. |
104+
| claim_validator.audience | object | False | | | [Audience claim](https://openid.net/specs/openid-connect-core-1_0.html) validation configurations. |
105+
| claim_validator.audience.claim | string | False | aud | | Name of the claim that contains the audience. |
106+
| claim_validator.audience.required | boolean | False | false | | If true, audience claim is required and the name of the claim will be the name defined in `claim`. |
107+
| claim_validator.audience.match_with_client_id | boolean | False | false | | If true, require the audience to match the client ID. If the audience is a string, it must exactly match the client ID. If the audience is an array of strings, at least one of the values must match the client ID. If no match is found, you will receive a `mismatched audience` error. This requirement is stated in the OpenID Connect specification to ensure that the token is intended for the specific client. |
103108
| claim_schema | object | False | | | JSON schema of OIDC response claim. Example: `{"type":"object","properties":{"access_token":{"type":"string"}},"required":["access_token"]}` - validates that the response contains a required string field `access_token`. |
104109

105110
NOTE: `encrypt_fields = {"client_secret"}` is also defined in the schema, which means that the field will be stored encrypted in etcd. See [encrypted storage fields](../plugin-develop.md#encrypted-storage-fields).

docs/zh/latest/plugins/openid-connect.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,12 @@ description: openid-connect 插件支持与 OpenID Connect (OIDC) 身份提供
9999
| introspection_interval | integer || 0 | | 缓存和自省访问令牌的 TTL(以秒为单位)。默认值为 0,这意味着不使用此选项,插件默认使用 `introspection_expiry_claim` 中定义的到期声明传递的 TTL。如果`introspection_interval` 大于 0 且小于 `introspection_expiry_claim` 中定义的到期声明传递的 TTL,则使用`introspection_interval`|
100100
| introspection_expiry_claim | string || exp | | 到期声明的名称,它控制缓存和自省访问令牌的 TTL。|
101101
| introspection_addon_headers | array[string] || | | 用于将其他标头值附加到自省 HTTP 请求。如果原始请求中不存在指定的标头,则不会附加值。|
102-
| claim_validator.issuer.valid_issuers | string[] || | | 将经过审查的 jwt 发行者列入白名单。当用户未传递时,将使用发现端点返回的颁发者。如果两者均缺失,发行人将无法得到验证|
102+
| claim_validator | object || | | JWT 声明(claim)验证的相关配置。 |
103+
| claim_validator.issuer.valid_issuers | array[string] || | | 可信任的 JWT 发行者(issuer)列表。如果未配置,将使用发现端点返回的发行者;如果两者都不可用,将不会验证发行者。 |
104+
| claim_validator.audience | object || | | [Audience 声明](https://openid.net/specs/openid-connect-core-1_0.html) 验证的相关配置。 |
105+
| claim_validator.audience.claim | string || aud | | 包含受众(audience)的声明名称。 |
106+
| claim_validator.audience.required | boolean || false | | 若为 `true`,则要求必须存在受众声明,其名称为 `claim` 中定义的值。 |
107+
| claim_validator.audience.match_with_client_id | boolean || false | | 若为 `true`,则要求受众(audience)必须与客户端 ID 匹配。若受众为字符串,则必须与客户端 ID 完全一致;若受众为字符串数组,则至少有一个值需与客户端 ID 匹配。若未找到匹配项,将返回 `mismatched audience` 错误。此要求来自 OpenID Connect 规范,用于确保令牌仅用于指定的客户端。 |
103108
| claim_schema | object || | | OIDC 响应 claim 的 JSON schema。示例:`{"type":"object","properties":{"access_token":{"type":"string"}},"required":["access_token"]}` - 验证响应中包含必需的字符串字段 `access_token`|
104109

105110
注意:schema 中还定义了 `encrypt_fields = {"client_secret"}`,这意味着该字段将会被加密存储在 etcd 中。具体参考 [加密存储字段](../plugin-develop.md#加密存储字段)

0 commit comments

Comments
 (0)