-
Notifications
You must be signed in to change notification settings - Fork 3
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
OIDC Dynamic Client Registration expiry hinders OIDC token refresh #142
Comments
Well @felix-schwarz - Don't use the client_id anymore, when its secret is expired. Since the refresh token is bound to the client_id value, also means you cannot use the refresh token once the client_id is expires. Having that said, and that the dynamic client secrets are only valid for 1 hour (as issued by Kopano Konnect), I can see that this is a problem. |
@longsleep Thanks for the clarification. I took another look into the specification and as you wrote above the
I couldn't find any explicit information in the Dynamic Client Registration spec as to whether a So I'm not sure if it would be in line with the standard to allow the usage of expired |
@felix-schwarz the only way i see which works would be non-expiring dynamic client registration. This is currently not possible with Kopano Konnect, but could be easily changed. I checked a bit around, and others also seem to be sending back |
@longsleep Thanks for sharing that! In the specs, nothing pointed to Regarding security, the dynamic A non-expiring dynamic So I think a good solution might be to allow admins to configure the timeout so that it meets their use case. A |
@felix-schwarz the
It cannot stay open for any period of time since it is bound to the validity of the refresh token (which usually have some very long expiration like 3 years or so as it is by default with Kopano Konnect https://github.com/Kopano-dev/konnect/blob/master/cmd/konnectd/serve.go#L98). I don't see a problem by simply giving avay dynamic client secrets which do not expire (by default) - i will play around with that a bit and change this in Konnect as dynamic client ids with 1 hour duration does not seem to make that much of sense. |
I am closing this in here - there is not much we can do within our openidconnect app |
@longsleep After @mmattel brought up this issue with me again, I did a quick research in the konnect code and ended up at this line: https://github.com/Kopano-dev/konnect/blob/master/cmd/konnectd/serve.go#L99 That line suggests to me that konnect now returns |
Yes, see libregraph/lico@08b5f4f for the full change and further expaination. That change got released with Konnect v0.34.0 about a year ago. |
Thanks for the confirmation and link to the commit @longsleep ! |
Summary
The ownCloud Android, Desktop and iOS clients are running into an issue with Kopano's OIDC implementation if:
refresh_token
was retrieved using a dynamically registered client IDrefresh_token
was usedTested cases
When sending the
refresh_token
together with theclient_id
/client_secret
with which is was retrieved, before theclient_id
has expired: all is fine.When sending the
refresh_token
together with theclient_id
/client_secret
with which is was retrieved, but after theclient_id
has expired:When sending the
refresh_token
together with a freshly issuedclient_id
/client_secret
at the time of sending the refresh request to the token endpoint:Can you help @longsleep?
The text was updated successfully, but these errors were encountered: