erlef / oidcc

OpenId Connect client library in Erlang & Elixir
https://hexdocs.pm/oidcc
Apache License 2.0
166 stars 44 forks source link

fix: url_extension params also go in the request object #354

Closed paulswartz closed 3 months ago

paulswartz commented 4 months ago

Originally done in #299, this doesn't seem correct in practice. In particular, a team ran into this issue with Keycloak, where passing the kc_action parameter only works when it's included in the request object.

I also tried this with the conformance suite, and all the tests continue to pass with this change.

The test failures in Zitadel seem unrelated, as I also see them on main; @maennchen any ideas there?

maennchen commented 3 months ago

@paulswartz I'm wondering if this is the correct course of actions. The parameter is called url_extension. Therefore it should go into the url.

I also haven't seen anywhere the explicitly forbids adding URL parameters when using request objects.

Maybe we have to introduce a new parameter?

That do you think?

coveralls commented 3 months ago

Pull Request Test Coverage Report for Build 189

Details


Totals Coverage Status
Change from base Build 177: 0.2%
Covered Lines: 1062
Relevant Lines: 1153

πŸ’› - Coveralls
paulswartz commented 3 months ago

Thanks for fixing the tests!

I dug back into the spec:

I'm thinking that the solution is to send the url_extension parameters both in the URL and the request object: what do you think?

maennchen commented 3 months ago

@paulswartz Agreed. Letβ€˜s do that πŸ‘

coveralls commented 3 months ago

Pull Request Test Coverage Report for Build 190

Details


Files with Coverage Reduction New Missed Lines %
src/oidcc_authorization.erl 1 94.06%
<!-- Total: 1 -->
Totals Coverage Status
Change from base Build 177: 0.09%
Covered Lines: 1061
Relevant Lines: 1153

πŸ’› - Coveralls
paulswartz commented 3 months ago

@maennchen this is ready for review now. I've tested it with the team that was experiencing the original issue and this addresses their issue.