Skip to content

Commit

Permalink
fix: correctly pass multiple token audiences and prompt parameters wh…
Browse files Browse the repository at this point in the history
…en performing the authorization code flow from the CLI
  • Loading branch information
alnr committed Mar 14, 2024
1 parent 8fff30d commit 6266558
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cmd/cmd_perform_authorization_code.go
Original file line number Diff line number Diff line change
Expand Up @@ -152,9 +152,9 @@ and success, unless if the --no-shutdown flag is provided.`,

authCodeURL := conf.AuthCodeURL(
state,
oauth2.SetAuthURLParam("audience", strings.Join(audience, "+")),
oauth2.SetAuthURLParam("audience", strings.Join(audience, " ")),

Check warning on line 155 in cmd/cmd_perform_authorization_code.go

View check run for this annotation

Codecov / codecov/patch

cmd/cmd_perform_authorization_code.go#L155

Added line #L155 was not covered by tests
oauth2.SetAuthURLParam("nonce", string(nonce)),
oauth2.SetAuthURLParam("prompt", strings.Join(prompt, "+")),
oauth2.SetAuthURLParam("prompt", strings.Join(prompt, " ")),

Check warning on line 157 in cmd/cmd_perform_authorization_code.go

View check run for this annotation

Codecov / codecov/patch

cmd/cmd_perform_authorization_code.go#L157

Added line #L157 was not covered by tests
oauth2.SetAuthURLParam("max_age", strconv.Itoa(maxAge)),
)
return authCodeURL, state
Expand Down

0 comments on commit 6266558

Please sign in to comment.