-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Ensure force PKCE always forces PKCE, fixes #1654 #1773
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Ensure force PKCE always forces PKCE, fixes #1654 #1773
Conversation
nbulaj
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks
|
how does this affect implementations currently forcing public apps to use pkce, but not confidential ones? unless i'm misunderstanding, this is a breaking change i'd have to pass on to third-party integrators, or disable the |
@gkemmey This would be a breaking change, in which case, I'd recommend disabling Keep in mind this would not affect client credentials grant flow, only authorization code grant flow. |
@ThisIsMissEm Can you say a little more about this perspective? While I love the idea of moving more providers and clients in the direction of the most secure methods of operation available, having some in-between functionality (i.e. a "partially on" state as the code works prior to this change) seems hugely beneficial for enabling apps to move in this more secure direction incrementally. I understand that's not ideal and makes for more code to maintain (I love the simplicity of this change!), but there seems like a reasonable amount of upside to that incremental/layered approach. |
|
If anything, we'd add a So like: Or something (you wouldn't have the grant type in here, because it's only But you could probably also do this with a custom extension, I think, in like the PreAuth code? |
|
Hey all. Thanks for the great insights! This indeed can affect existing projects & customers so I think if we need to add some warning message? Or at least a changelog entry with a |
|
@nbulaj yeah, we could ship this and my other changes as a 6.x and just indicate major breaking changes |
|
if we ship this as is, there will be no doorkeeper-supported way to recover the existing behavior where pkce is only required for public clients. i'd like to continue forcing public clients to use pkce, but avoid forcing third-party integrators to update their confidential oauth apps to use pkce. are we deciding that behavior will have to be patched in? if not and we’re willing to make a breaking change to |
|
@gkemmey that looks like overall a good change, but I think we should continue having |
|
@gkemmey if you want, open up that branch as a pull request against ThisIsMissEm:fix/allow-force-pkce-for-all-clients and I'll rebase it in, keeping authorship. |
|
that makes perfect sense! opened the pr here. don't feel like you have to use it if it's easier to just make the changes yourself. thanks! 🙏 |
Summary
Previously
force_pkceoption could be bypassed if the client was confidential, that's no longer the case with the Security Practices BCP, which recommends PKCE for all clients.Fixes #1654
This is technically a breaking change
Other Information
We could perhaps simplify the tests a little, but I'm not sure that's necessary right now.