fosite icon indicating copy to clipboard operation
fosite copied to clipboard

Should the JWK "use" parameter be optional?

Open FenTiger opened this issue 10 months ago • 3 comments

Preflight checklist

Ory Network Project

No response

Describe your problem

Counterpart to https://github.com/likeandscribe/frontpage/issues/237:

When using "private_key_jwt" authentication, Fosite refuses to accept keys which don't have "use": "sig".

RFC7517 states

Use of the "use" member is OPTIONAL, unless the application requires its presence.

Should there be a way to disable this check?

Describe your ideal solution

A way to disable this check; perhaps a way to customise the search for public keys without having to override the whole of DefaultClientAuthenticationStrategy().

Workarounds or alternatives

Adding the "use" parameter to frontpage.fyi's key, per https://github.com/likeandscribe/frontpage/issues/237

Version

v0.46.1

Additional Context

No response

FenTiger avatar Apr 16 '25 11:04 FenTiger

See also: https://github.com/bluesky-social/atproto/discussions/3757

FenTiger avatar Apr 16 '25 11:04 FenTiger

This is configurable. Just copy the strategy and make the adjustments you want then assign it appropriately.

james-d-elliott avatar Apr 17 '25 02:04 james-d-elliott

Just copy the strategy

Yes, this is possible, but it doesn't seem ideal to have to make a local copy of >300 lines of code purely to make one small adjustment to it.

Mostly it does exactly what I want, so I think it would be far better to be able to "fine-tune" it rather than having to copy it wholesale and subsequently keep it up to date if/when it changes upstream.

FenTiger avatar May 23 '25 12:05 FenTiger