我正在处理一个 B2C 案例,该案例涉及使用 OpenIdConnect 与第 3 方身份提供者集成。
该第三方期望一个特定的查询字符串参数被发送一次或多次:
example.com/oidc/authorize=?...& login_hint =ABCvalue& login_hint =XYZvalue
我有一个 OpenIdConnect 技术配置文件,其中包含所需的输入声明:
<TechnicalProfile Id="Example-Swe">
<DisplayName>Example Sverige</DisplayName>
<Description>Login with Example</Description>
<Protocol Name="OpenIdConnect"/>
<OutputTokenFormat>JWT</OutputTokenFormat>
<Metadata>
<Item Key="client_id">preprod.Example</Item>
<Item Key="METADATA">https://example.com/oidc/.well-known/openid-configuration</Item>
<Item Key="response_types">code</Item>
<Item Key="scope">openid phone profile example.national_id offline_access</Item>
<Item Key="response_mode">query</Item>
<Item Key="HttpBinding">POST</Item>
<Item Key="UsePolicyInRedirectUri">false</Item>
</Metadata>
<CryptographicKeys>
<Key Id="client_secret" StorageReferenceId="B2C_1A_ExampleSecretNO1"/>
</CryptographicKeys>
<InputClaims>
<InputClaim ClaimTypeReferenceId="acr_values" DefaultValue="urn:example:oidc:method:sbid"/>
<InputClaim ClaimTypeReferenceId="example_profile" DefaultValue="example-id" />
<InputClaim ClaimTypeReferenceId="ui_locales" DefaultValue="sv" />
<InputClaim ClaimTypeReferenceId="claimABC" PartnerClaimType="login_hint" />
<InputClaim ClaimTypeReferenceId="claimXYZ" PartnerClaimType="login_hint" />
</InputClaims>
<OutputClaims>
<OutputClaim ClaimTypeReferenceId="access_token" PartnerClaimType="{oauth2:access_token}" />
<OutputClaim ClaimTypeReferenceId="issuerUserId" PartnerClaimType="sub" />
<OutputClaim ClaimTypeReferenceId="authenticationSource" DefaultValue="SigBidSwe" />
<OutputClaim ClaimTypeReferenceId="identityProvider" DefaultValue="Example-BID-Swe" />
<OutputClaim ClaimTypeReferenceId="countryCode" DefaultValue="SE" AlwaysUseDefaultValue="true" />
</OutputClaims>
<UseTechnicalProfileForSessionManagement ReferenceId="SM-AAD"/>
</TechnicalProfile>
但是有两个具有相同 PartnerClaimType 的声明不起作用。B2C 抛出异常。
有可能以某种方式实现这一目标吗?