Reputation: 125
Is it possible to read a custom query string parameter from a SAML2 relying party request?.
Using the {OAUTH-KV:any custom query string} does not work.
example:
https://mytest.b2clogin.com/mytest.onmicrosoft.com/B2C_1A_TEST_SAML/samlp/sso/login?myparameter=true
I need to read the "myparameter" value into a claim.
Upvotes: 1
Views: 1581
Reputation: 894
Hope you are trying to do the following:
<InputClaims>
<InputClaim ClaimTypeReferenceId="givenName" DefaultValue="{OAUTH-KV:name}" />
</InputClaims>
To get the value from the query string you have to configure the metadata of the technical profile and set the AlwaysUseDefaultValue property of the input claim like the following:
<Metadata>
<Item Key="IncludeClaimResolvingInClaimsHandling">true</Item>
</Metadata>
and
<InputClaims>
<InputClaim ClaimTypeReferenceId="givenName" AlwaysUseDefaultValue="true" DefaultValue="{OAUTH-KV:name}" />
</InputClaims>
Upvotes: 7