Skip to content

Commit

Permalink
Send new params to management ui
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcialRosales committed Sep 20, 2024
1 parent 3a210d7 commit 5504335
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
9 changes: 7 additions & 2 deletions deps/oauth2_client/src/oauth2_client.erl
Original file line number Diff line number Diff line change
Expand Up @@ -77,12 +77,17 @@ build_openid_discovery_endpoint(Issuer, OpenIdConfigurationPath, Params) ->
{_, Q} ->
URLMap1#{query => uri_string:compose_query(Q ++ Params)}
end).
ensure_leading_path_separator(Path) ->
ensure_leading_path_separator(Path) when is_binary(Path) ->
ensure_leading_path_separator(binary:bin_to_list(Path));
ensure_leading_path_separator(Path) when is_list(Path) ->
case string:slice(Path, 0, 1) of
"/" -> Path;
_ -> "/" ++ Path
end.
drop_trailing_path_separator(Path) ->
drop_trailing_path_separator(Path) when is_binary(Path) ->
drop_trailing_path_separator(binary:bin_to_list(Path));
drop_trailing_path_separator("") -> "";
drop_trailing_path_separator(Path) when is_list(Path) ->
case string:slice(Path, string:len(Path)-1, 1) of
"/" -> lists:droplast(Path);
_ -> Path
Expand Down
4 changes: 3 additions & 1 deletion deps/rabbitmq_management/src/rabbit_mgmt_wm_auth.erl
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,9 @@ produce_auth_settings(MgtResourceServers, ManagementProps) ->
case proplists:get_value(oauth_initiated_logon_type, ManagementProps, sp_initiated) of
sp_initiated -> {};
idp_initiated -> {oauth_initiated_logon_type, <<"idp_initiated">>}
end
end,
to_tuple(oauth_authorization_endpoint_params, ManagementProps),
to_tuple(oauth_token_endpoint_params, ManagementProps)
])
end.

Expand Down

0 comments on commit 5504335

Please sign in to comment.