Invalid Key Error with Simple OAuth 5.2.3, lcobucci/jwt 4.3.0, and steverhoades/oauth2-openid-connect-server 2.5.0

Created on 6 February 2023, over 1 year ago
Updated 22 February 2023, over 1 year ago

I am not sure if this is an issue related to Simple OAuth or not. Also, I am not sure if someone else is experiencing this issue or not.

Configuration:
* Drupal 9.5.3 (it also occurred with 9.5.2)
* Simple OAuth 5.2.3
* Lcobucci\JWT 4.3.0
* SteverHoades/oauth2-openid-connect-server 2.5.0

An issue arises after updating steverhoades/oauth2-openid-connect-server (v2.4.0 to v2.5.0), and therefore lcobucci/jwt (4.1.5 => 4.3.0). After updating, the following error occur in the Drupal log:

Lcobucci\JWT\Signer\InvalidKeyProvided: Key cannot be empty in Lcobucci\JWT\Signer\InvalidKeyProvided::cannotBeEmpty()

Nothing else has changed on my end, excluding these two packages. This is using a custom API endpoint defined within a custom module's routing.yml file.

This works with jwt 4.1.5. and oauth2-openid-connect-server 2.4.0. I know that oauth2-openid-connect-server 2.5.0 requires jwt 4.2 or newer. The key length is not the issue, as it exceeds the minimum needed.

I do not know if this is working properly on the latest versions with 6.x-dev. If it does then I will not worry about making it work with the 5.x line, and plan on upgrading to 6.0 when it is released. Also, if this is not an issue with simple_oauth at all, but should be directed elsewhere, I would appreciate knowing that as well.

πŸ› Bug report
Status

Active

Version

5.2

Component

Code

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.69.0 2024