
![[8.5.5.4 或更新版本]](../ng_v8554.gif)
將「OpenID Connect 提供者」配置成接受探索要求
探索配置端點提供「OpenID Connect 提供者」伺服器所支援功能的相關資訊。
關於這項作業
這項服務傳回的 meta 資料是以 OIDC Discovery 1.0 規格提供者 meta 資料為基礎,並加以延伸。如果都沒有指定,服務會傳回一組預設配置。否則,請參閱內容清單,瞭解其用途和可能的可配置選項。
程序
您可以置換探索配置服務中所選內容的預設值。您可以在 server.xml 檔中指定值,來執行這個動作。請參閱以下的內容表,檢視可配置的內容和可能的配置選項。
屬性名稱 | 資料類型 | 必要/選用 | 說明 |
---|---|---|---|
responseTypesSupported | 輸入 | 選用 | 「OpenID Connect 提供者 (OP)」伺服器支援的回應類型。除非另有指定,預設值為 code、token 和 id_token
token。可以指定多值。這些值是字串。例如,可能的值如下:
|
subjectTypesSupported | 僅輸出 | N/A | OP 伺服器支援的主體類型。此值會設為 public。此值是字串。 |
idTokenSigningAlgValuesSupported | 僅輸出 | 選用 | OP 伺服器支援的 ID 記號簽章演算法。此值會在 openidConnectProvider 伺服器配置中指定成伺服器屬性 signatureAlgorithm。除非另有指定,預設值為 HS256。只能指定一值。這是字串。舉例來說,在 openidConnectProvider 配置中,signatureAlgorithm 屬性的可能值如下:
|
scopesSupported | 輸入 | 選用 | OP 伺服器支援的範圍值。除非另有指定,預設值為 openid、general、profile、email、address 和 phone。可以指定多值。這些值是字串。例如,可能的值如下:
|
claimsSupported | 輸入 | 選用 | OP 伺服器支援的聲明值。除非另有指定,預設值為 sub、groupIds、name、preferred_username、picture、locale、email 和 profile。可以指定多值。這些值是字串。例如,可能的值如下:
|
responseModesSupported | 輸入 | 選用 | OP 伺服器支援的回應模式。除非另有指定,預設值為 query 和 fragment。可以指定多值。這些值是字串。
|
grantTypesSupported | 輸入 | 選用 | OP 伺服器支援的授權類型。除非另有指定,預設值為 authorization_code、implicit、refresh_token、client_credentials、password 和 urn:ietf:params:oauth:grant-type:jwtbearer。可以指定多值。這些值是字串。例如,可能的值如下:
|
tokenEndpointAuthMethodsSupported | 輸入 | 選用 | OP 伺服器支援的記號端點授權方法。除非另有指定,預設值為 client_secret_post 和 client_secret_basic。可以指定多值。這些值是字串。例如,可能的值如下:
|
displayValuesSupported | 僅輸出 | N/A | OP 伺服器支援的顯示值。此值會設為 page。此值是字串。 |
claimTypesSupported | 僅輸出 | N/A | OP 伺服器支援的聲明類型值。此值會設為 normal。此值是字串。 |
claimsParameterSupported | 輸入 | 選用 | 指出 OP 伺服器是否支援聲明參數。除非另有指定,預設值為 false。只能指定一值。這是布林值。例如,可能的值如下:
|
requestParameterSupported | 輸入 | 選用 | 指出 OP 伺服器是否支援要求參數。除非另有指定,預設值為 false。只能指定一值。這是布林值。例如,可能的值如下:
|
requestUriParameterSupported | 輸入 | 選用 | 指出 OP 伺服器是否支援要求 URI 參數。除非另有指定,預設值為 false。只能指定一值。這是布林值。例如,可能的值如下:
|
requireRequestUriRegistration | 輸入 | 選用 | 指出 OP 伺服器是否支援「需要要求 URI 登錄」。除非另有指定,預設值為 false。只能指定一值。這是布林值。例如,可能的值如下:
|
探索配置範例
下列範例假設 Liberty OP 是配置成使用 SSL 埠 443。
https://server.example.com:443/oidc/endpoint/<provider_name>/
探索配置端點可從下列存取:
https://server.example.com:443/oidc/endpoint/<provider_name>/.well-known/openid-configuration
例如,在 server.xml 檔中,使用者可以採下列方式來自訂其 OpenID Connect 探索配置內容:
<openidConnectProvider id="OidcConfigSample" oauthProviderRef="OAuthConfigSample">
<discovery
responseTypesSupported="token, id_token token"
subjectTypesSupported="public"
scopesSupported="openid, general, profile"
claimsSupported="sub, groupIds, name"
responseModesSupported="query"
grantTypesSupported="implicit"
tokenEndpointAuthMethodsSupported="client_secret_basic"
displayValuesSupported="page"
claimTypesSupported="normal"
claimsParameterSupported="true"
requestParameterSupported="true"
requestUriParameterSupported="true"
requireRequestUriRegistration="true"
/>
</openidConnectProvider>
<oauthProvider id="OAuthConfigSample">
</oauthProvider>
Request Headers: GET https://server.example.com:443/oidc/endpoint/<provider_name>/.well-known/openid-configuration Response Headers: Status: 200 Content-Type: application/json Cache-Control:public, max-age=3600 Response Body: { "introspection_endpoint":"https://server.example.com:443/oidc/endpoint/<provider_name>/introspect", "coverage_map_endpoint":"https://server.example.com:443/oidc/endpoint/<provider_name>/coverage_map", "issuer":"https://server.example.com:443/oidc/endpoint/<provider_name>", "authorization_endpoint":"https://server.example.com:443/oidc/endpoint/<provider_name>/authorize", "token_endpoint":"https://server.example.com:443/oidc/endpoint/<provider_name>/token", "response_types_supported":[ "token", "id_token token" ], "subject_types_supported":[ "public" ], "userinfo_endpoint":"https://server.example.com:443/oidc/endpoint/<provider_name>/userinfo", "registration_endpoint":"https://server.example.com:443/oidc/endpoint/<provider_name>/registration", "scopes_supported":[ "openid", "general", "profile" ], "claims_supported":[ "sub", "groupIds", "name" ], "response_modes_supported":[ "query" ], "grant_types_supported":[ "implicit" ], "token_endpoint_auth_methods_supported":[ "client_secret_basic" ], "display_values_supported":[ "page" ], "claim_types_supported":[ "normal" ], "claims_parameter_supported":true, "request_parameter_supported":true, "request_uri_parameter_supported":true, "require_request_uri_registration":true, "check_session_iframe":"https://server.example.com:443/oidc/endpoint/<provider_name>/check_session_iframe", "end_session_endpoint":"https://server.example.com:443/oidc/endpoint/<provider_name>/end_session" }
Request Headers: GET https://server.example.com:443/oidc/endpoint/<provider_name>/.well-known/openid-configuration Response Headers: Status: 200 Content-Type: application/json Cache-Control:public, max-age=3600 Response Body: { "introspection_endpoint":"https://server.example.com:443/oidc/endpoint/<provider_name>/introspect", "coverage_map_endpoint":"https://server.example.com:443/oidc/endpoint/<provider_name>/coverage_map", "issuer":"https://server.example.com:443/oidc/endpoint/<provider_name>", "authorization_endpoint":"https://server.example.com:443/oidc/endpoint/<provider_name>/authorize", "token_endpoint":"https://server.example.com:443/oidc/endpoint/<provider_name>/token", "response_types_supported":[ "code", "token", "id_token token" ], "subject_types_supported":[ "public" ], "userinfo_endpoint":"https://server.example.com:443/oidc/endpoint/<provider_name>/userinfo", "registration_endpoint":"https://server.example.com:443/oidc/endpoint/<provider_name>/registration", "scopes_supported":[ "openid", "general", "profile", "email", "address", "phone" ], "claims_supported":[ "sub", "groupIds", "name", "preferred_username", "picture", "locale", "email", "profile" ], "response_modes_supported":[ "query", "fragment" ], "grant_types_supported":[ "authorization_code", "implicit", "refresh_token", "client_credentials", "password", "urn:ietf:params:oauth:grant-type:jwt-bearer" ], "token_endpoint_auth_methods_supported":[ "client_secret_post", "client_secret_basic" ], "display_values_supported":[ "page" ], "claim_types_supported":[ "normal" ], "claims_parameter_supported":false, "request_parameter_supported":false, "request_uri_parameter_supported":false, "require_request_uri_registration":false, "check_session_iframe":"https://server.example.com:443/oidc/endpoint/<provider_name>/check_session_iframe", "end_session_endpoint":"https://server.example.com:443/oidc/endpoint/<provider_name>/end_session" }