Skip to content
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

Update dependency django-oauth-toolkit to v2 #2376

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Aug 30, 2024

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
django-oauth-toolkit ^1.7.0 -> ^2.0.0 age adoption passing confidence

Release Notes

jazzband/django-oauth-toolkit (django-oauth-toolkit)

v2.4.0

Compare Source

WARNING

Issues caused by Release 2.0.0 breaking changes continue to be logged. Please make sure to carefully read these release notes before
performing a MAJOR upgrade to 2.x.

These issues both result in {"error": "invalid_client"}:

  1. The application client secret is now hashed upon save. You must copy it before it is saved. Using the hashed value will fail.

  2. PKCE_REQUIRED is now True by default. You should use PKCE with your client or set PKCE_REQUIRED=False if you are unable to fix the client.

If you are going to revert migration 0006 make note that previously hashed client_secret cannot be reverted!

Added
Fixed
  • #​1292 Interpret EXP in AccessToken always as UTC instead of (possibly) local timezone.
    Use setting AUTHENTICATION_SERVER_EXP_TIME_ZONE to enable different time zone in case the remote
    authentication server does not provide EXP in UTC.
  • #​1323 Fix instructions in documentation
    on how to create a code challenge and code verifier
  • #​1284 Fix a 500 error when trying to logout with no id_token_hint even if the browser session already expired.
  • #​1296 Added reverse function in migration 0006_alter_application_client_secret. Note that reversing this migration cannot undo a hashed client_secret.
  • #​1345 Fix encapsulation for Redirect URI scheme validation. Deprecates RedirectURIValidator in favor of AllowedURIValidator.
  • #​1357 Move import of setting_changed signal from test to django core modules.
  • #​1361 Fix prompt=none redirects to login screen
  • #​1380 Fix AttributeError in OAuth2ExtraTokenMiddleware when a custom AccessToken model is used.
  • #​1288 Fix #​1276 which attempted to resolve #​1092 for requests that don't have a client_secret per RFC 6749 4.1.1
  • #​1337 Gracefully handle expired or deleted refresh tokens, in validate_user.
  • Various documentation improvements: #​1410, #​1408, #​1405, #​1399, #​1401, #​1396, #​1375, #​1162, #​1315, #​1307
Removed
  • #​1350 Remove support for Python 3.7 and Django 2.2

v2.3.0

Compare Source

WARNING

Issues caused by Release 2.0.0 breaking changes continue to be logged. Please make sure to carefully read these release notes before
performing a MAJOR upgrade to 2.x.

These issues both result in {"error": "invalid_client"}:

  1. The application client secret is now hashed upon save. You must copy it before it is saved. Using the hashed value will fail.

  2. PKCE_REQUIRED is now True by default. You should use PKCE with your client or set PKCE_REQUIRED=False if you are unable to fix the client.

Added
Changed

v2.2.0

Compare Source

Added
  • #​1208 Add 'code_challenge_method' parameter to authorization call in documentation
  • #​1182 Add 'code_verifier' parameter to token requests in documentation
Changed
Fixed
  • #​1203 Remove upper version bound on Django, to allow upgrading to Django 4.1.1 bugfix release.
  • #​1210 Handle oauthlib errors on create token requests

v2.1.0

Compare Source

Added
Changed
  • #​1152 createapplication management command enhanced to display an auto-generated secret before it gets hashed.
  • #​1172, #​1159, #​1158 documentation improvements.
Fixed
  • #​1147 Fixed 2.0.0 implementation of hashed client secret to work with swapped models.

v2.0.0

Compare Source

This is a major release with BREAKING changes. Please make sure to review these changes before upgrading:

Added
Changed
  • #​1129 (Breaking) Changed default value of PKCE_REQUIRED to True. This is a breaking change. Clients without
    PKCE enabled will fail to authenticate. This breaks with section 5 of RFC7636
    in favor of the OAuth2 Security Best Practices for Authorization Code Grants.
    If you want to retain the pre-2.x behavior, set PKCE_REQUIRED = False in your settings.py
  • #​1093 (Breaking) Changed to implement hashed
    client_secret values. This is a breaking change that will migrate all your existing
    cleartext application.client_secret values to be hashed with Django's default password hashing algorithm
    and can not be reversed. When adding or modifying an Application in the Admin console, you must copy the
    auto-generated or manually-entered client_secret before hitting Save.
  • #​1108 OIDC: (Breaking) Add default configurable OIDC standard scopes that determine which claims are returned.
    If you've customized OIDC responses
    and want to retain the pre-2.x behavior, set oidc_claim_scope = None in your subclass of OAuth2Validator.
  • #​1108 OIDC: Make the access_token available to get_oidc_claims when called from get_userinfo_claims.
  • #​1132: Added --algorithm argument to createapplication management command
Fixed
  • #​1108 OIDC: Fix validate_bearer_token() to properly set request.scopes to the list of granted scopes.
  • #​1132: Fixed help text for --skip-authorization argument of the createapplication management command.
Removed
  • #​1124 (Breaking, Security) Removes support for insecure urn:ietf:wg:oauth:2.0:oob and urn:ietf:wg:oauth:2.0:oob:auto which are replaced
    by RFC 8252 "OAuth 2.0 for Native Apps" BCP. Google has
    deprecated use of oob with
    a final end date of 2022-10-03. If you still rely on oob support in django-oauth-toolkit, do not upgrade to this release.

Configuration

📅 Schedule: Branch creation - "every weekend" in timezone US/Eastern, Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate bot force-pushed the renovate/django-oauth-toolkit-2.x branch 6 times, most recently from 2bd262d to 0dc5678 Compare September 5, 2024 14:34
@renovate renovate bot force-pushed the renovate/django-oauth-toolkit-2.x branch from 0dc5678 to e94c259 Compare September 6, 2024 13:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants