You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The mock-oauth2-server responds to token requests with a signed token with ${participantId}, ${actAs}, and ${readAs} replaced with values from the token request. Here is a sample of what I'm looking for:
when (value) {
is String -> replaceVariables(value, variables)
is List<*> ->
value.map { v ->
if (v is String) {
replaceVariables(v, variables)
} else {
v
}
}
else -> value
}
This code would need to be updated to recurse the fields of child objects. Or, perhaps more simply, perform the substitution on the full claims JSON string, instead of the individual claims.
The text was updated successfully, but these errors were encountered:
@wallacekelly-da are the parameters participantId, actAs, readAs part of the token request? The only way we can use dynamic values in the returned token for a specific request mapping is if we receive them as a part of the token request. Can you provide a sample of the token request?
Repro steps
Motivated by this, define a request mapping in the JSON config file:
Desired Behavior
The mock-oauth2-server responds to token requests with a signed token with
${participantId}
,${actAs}
, and${readAs}
replaced with values from the token request. Here is a sample of what I'm looking for:Current Behavior
The fields
${participantId}
,${actAs}
, and${readAs}
are not replaced. Here is an example of what is returned:Related code
It looks like the
replaceVariables
function is only being applied to the first-level strings and lists of strings.From OAuth2TokenCallback.kt:
This code would need to be updated to recurse the fields of child objects. Or, perhaps more simply, perform the substitution on the full claims JSON string, instead of the individual claims.
The text was updated successfully, but these errors were encountered: