1
0

Compare commits

19 Commits

Author SHA256 Message Date
c1cbb76649 Accepting request 1315319 from devel:languages:python:django
OBS-URL: https://build.opensuse.org/request/show/1315319
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-djangorestframework-simplejwt?expand=0&rev=9
2025-11-03 17:56:15 +00:00
9e28694865 - Update to 5.5.1 (CVE-2024-22513, bsc#1221568)
* Changed string formatting in views
  * Enhance BlacklistMixin with Generic Type for Accurate Type Inference
  * Improve type of Token.for_user to allow subclasses
  * Fix the Null value of the OutstandingToken of the BlacklistMixin.blacklist
  * Add option to allow inactive user authentication and token generation
  * Add support for EdDSA and other algorithms in jwt.algorithms.requires_cryptography
  * Drop Django <4.2, DRF <3.14, Python <3.9. Note, many deprecated versions are only
    officially not supported but probably still work fine.
  * Add specific "token expired" exceptions
  * Fix user_id type mismatch when user claim is not pk
  * Caching signing key
  * fix: add missing migration for token_blacklist app
  * docs: Add warning in docs for for_user usage
  * feat: log warning if token is being created for inactive user
  * fix: always stringify user_id claim
- Drop fix-tests.patch, merged upstream

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:django/python-djangorestframework-simplejwt?expand=0&rev=9
2025-11-03 14:28:58 +00:00
16b8f420ce Accepting request 1223466 from devel:languages:python:django
Forwarded request #1223408 from mcalabkova

- Add missing dependency

OBS-URL: https://build.opensuse.org/request/show/1223466
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-djangorestframework-simplejwt?expand=0&rev=8
2024-11-12 18:22:00 +00:00
ab7e7d9f04 - Add missing dependency
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:django/python-djangorestframework-simplejwt?expand=0&rev=7
2024-11-12 01:21:40 +00:00
477ee5bb1f Accepting request 1188599 from devel:languages:python:django
OBS-URL: https://build.opensuse.org/request/show/1188599
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-djangorestframework-simplejwt?expand=0&rev=7
2024-07-22 15:15:54 +00:00
bf9ae18e8f Accepting request 1183075 from devel:languages:python:django
- Switch back to PyPi tarball.
- Inject setuptools_scm so we install the correct version number.
- Switch to autosetup macro.
- No more greedy globs in %files.

- Update to 5.3.1
  * Breaking: Set BLACKLIST_AFTER_ROTATION by default to False
  * Remove EOL Python, Django and DRF version support
  * Remove verify from jwt.decode to follow PyJWT v2.2.0
  * Add blacklist view to log out users
  * Add JWKS support
  * Add back support for PyJWT 1.7.1
  * Allow customizing token JSON encoding
  * Revoke access token if user password is changed
  * Declare support for type checking
  * Many more changes, see CHANGELOG.md
- Drop patch jwt2.patch, included upstream.

OBS-URL: https://build.opensuse.org/request/show/1183075
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-djangorestframework-simplejwt?expand=0&rev=6
2024-06-25 21:07:42 +00:00
812c8ed4fd Mention dropped patch.
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:django/python-djangorestframework-simplejwt?expand=0&rev=3
2024-06-25 03:02:08 +00:00
b819937497 - Switch back to PyPi tarball.
- Inject setuptools_scm so we install the correct version number.
- Switch to autosetup macro.
- No more greedy globs in %files.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:django/python-djangorestframework-simplejwt?expand=0&rev=2
2024-06-24 04:50:44 +00:00
fcee264765 osc copypac from project:devel:languages:python package:python-djangorestframework-simplejwt revision:11
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:django/python-djangorestframework-simplejwt?expand=0&rev=1
2024-06-24 04:19:09 +00:00
05eccdee9b Accepting request 1162954 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/1162954
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-djangorestframework-simplejwt?expand=0&rev=5
2024-03-27 19:43:48 +00:00
50699470c4 Accepting request 1162496 from home:mlin7442:rebuild_fails_156
Add %{?sle15_python_module_pythons}

OBS-URL: https://build.opensuse.org/request/show/1162496
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-djangorestframework-simplejwt?expand=0&rev=9
2024-03-27 16:39:14 +00:00
Richard Brown
27ac0547c0 Accepting request 882386 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/882386
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-djangorestframework-simplejwt?expand=0&rev=4
2021-04-01 12:17:56 +00:00
a9c8c3e042 Accepting request 882384 from home:mcalabkova:branches:devel:languages:python
- Update to 4.6.0
  * Restored Python 3.7 support
  * Added Indonesian translations
  * Fixed Django 4.0 re_path deprecation
- Add patch jwt2.patch for PyJWT>=2.0.0 support

OBS-URL: https://build.opensuse.org/request/show/882384
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-djangorestframework-simplejwt?expand=0&rev=7
2021-03-31 14:29:53 +00:00
0fa8fbc3f2 Accepting request 822655 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/822655
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-djangorestframework-simplejwt?expand=0&rev=3
2020-07-26 14:18:57 +00:00
Tomáš Chvátal
ac96ce839a Accepting request 822573 from home:jayvdb:django
- Update to v4.4.0
  * Added official support for Python 3.8 and Django 3.0.
  * Added settings for expected audience and issuer claims.
  * Documentation updates.
  * Updated package/python version support
  * Added Chilean Spanish language support.
  * Added Russian language support.

OBS-URL: https://build.opensuse.org/request/show/822573
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-djangorestframework-simplejwt?expand=0&rev=5
2020-07-24 14:06:23 +00:00
Ludwig Nussel
79828fa2ed Accepting request 730636 from devel:languages:python
- Update to 4.3.0:
  * Added JTI_CLAIM setting to allow storing token identifiers under a different claim.
  * We now return HTTP 401 for user not found or inactive.
  * Restricted setup.py config to Python 3 only.
  * Included translation files in release package.

OBS-URL: https://build.opensuse.org/request/show/730636
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-djangorestframework-simplejwt?expand=0&rev=2
2019-09-13 13:03:26 +00:00
Tomáš Chvátal
2406b9f263 - Update to 4.3.0:
* Added JTI_CLAIM setting to allow storing token identifiers under a different claim.
  * We now return HTTP 401 for user not found or inactive.
  * Restricted setup.py config to Python 3 only.
  * Included translation files in release package.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-djangorestframework-simplejwt?expand=0&rev=3
2019-09-13 08:52:35 +00:00
b6f941d00c Accepting request 695468 from devel:languages:python
- Initial spec for v4.1.3

OBS-URL: https://build.opensuse.org/request/show/695468
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-djangorestframework-simplejwt?expand=0&rev=1
2019-04-23 12:35:38 +00:00
Tomáš Chvátal
fc53b712dc Accepting request 695401 from home:jayvdb:django
- Initial spec for v4.1.3

OBS-URL: https://build.opensuse.org/request/show/695401
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-djangorestframework-simplejwt?expand=0&rev=1
2019-04-18 07:52:52 +00:00
5 changed files with 33 additions and 79 deletions

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:6c4bd37537440bc439564ebf7d6085e74c5411485197073f508ebdfa34bc9fae
size 94266

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:e72c5572f51d7803021288e2057afcbd03f17fe11d484096f40a460abc76e87f
size 101265

View File

@@ -1,72 +0,0 @@
From 0b50ee6721155ce0f652d4c1f47dcbb10c191894 Mon Sep 17 00:00:00 2001
From: Mike <mike@zivix.com>
Date: Mon, 4 Dec 2023 17:48:36 -0800
Subject: [PATCH] Fix tests (#769)
---
rest_framework_simplejwt/utils.py | 5 ++---
tests/test_init.py | 5 ++---
tests/test_utils.py | 11 ++++-------
3 files changed, 8 insertions(+), 13 deletions(-)
Index: djangorestframework_simplejwt-5.3.1/rest_framework_simplejwt/utils.py
===================================================================
--- djangorestframework_simplejwt-5.3.1.orig/rest_framework_simplejwt/utils.py
+++ djangorestframework_simplejwt-5.3.1/rest_framework_simplejwt/utils.py
@@ -5,7 +5,6 @@ from typing import Callable
from django.conf import settings
from django.utils.functional import lazy
-from django.utils.timezone import is_naive, make_aware
def get_md5_hash_password(password: str) -> str:
@@ -16,8 +15,8 @@ def get_md5_hash_password(password: str)
def make_utc(dt: datetime) -> datetime:
- if settings.USE_TZ and is_naive(dt):
- return make_aware(dt, timezone=timezone.utc)
+ if settings.USE_TZ and dt.tzinfo is None:
+ return dt.replace(tzinfo=timezone.utc)
return dt
Index: djangorestframework_simplejwt-5.3.1/tests/test_utils.py
===================================================================
--- djangorestframework_simplejwt-5.3.1.orig/tests/test_utils.py
+++ djangorestframework_simplejwt-5.3.1/tests/test_utils.py
@@ -1,7 +1,6 @@
-from datetime import datetime, timedelta
+from datetime import datetime, timedelta, timezone
from django.test import TestCase
-from django.utils import timezone
from freezegun import freeze_time
from rest_framework_simplejwt.utils import (
@@ -24,11 +23,11 @@ class TestMakeUtc(TestCase):
with self.settings(USE_TZ=False):
dt = make_utc(dt)
- self.assertTrue(timezone.is_naive(dt))
+ self.assertTrue(dt.tzinfo is None)
with self.settings(USE_TZ=True):
dt = make_utc(dt)
- self.assertTrue(timezone.is_aware(dt))
+ self.assertTrue(dt.tzinfo is not None)
self.assertEqual(dt.utcoffset(), timedelta(seconds=0))
@@ -39,9 +38,7 @@ class TestAwareUtcnow(TestCase):
with freeze_time(now):
# Should return aware utcnow if USE_TZ == True
with self.settings(USE_TZ=True):
- self.assertEqual(
- timezone.make_aware(now, timezone=timezone.utc), aware_utcnow()
- )
+ self.assertEqual(now.replace(tzinfo=timezone.utc), aware_utcnow())
# Should return naive utcnow if USE_TZ == False
with self.settings(USE_TZ=False):

View File

@@ -1,3 +1,29 @@
-------------------------------------------------------------------
Mon Nov 3 09:29:49 UTC 2025 - Markéta Machová <mmachova@suse.com>
- Update to 5.5.1 (CVE-2024-22513, bsc#1221568)
* Changed string formatting in views
* Enhance BlacklistMixin with Generic Type for Accurate Type Inference
* Improve type of Token.for_user to allow subclasses
* Fix the Null value of the OutstandingToken of the BlacklistMixin.blacklist
* Add option to allow inactive user authentication and token generation
* Add support for EdDSA and other algorithms in jwt.algorithms.requires_cryptography
* Drop Django <4.2, DRF <3.14, Python <3.9. Note, many deprecated versions are only
officially not supported but probably still work fine.
* Add specific "token expired" exceptions
* Fix user_id type mismatch when user claim is not pk
* Caching signing key
* fix: add missing migration for token_blacklist app
* docs: Add warning in docs for for_user usage
* feat: log warning if token is being created for inactive user
* fix: always stringify user_id claim
- Drop fix-tests.patch, merged upstream
-------------------------------------------------------------------
Mon Nov 11 16:58:30 UTC 2024 - Markéta Machová <mmachova@suse.com>
- Add missing dependency
-------------------------------------------------------------------
Fri Jul 19 11:26:13 UTC 2024 - Markéta Machová <mmachova@suse.com>

View File

@@ -1,7 +1,7 @@
#
# spec file for package python-djangorestframework-simplejwt
#
# Copyright (c) 2024 SUSE LLC
# Copyright (c) 2025 SUSE LLC and contributors
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -18,16 +18,15 @@
%{?sle15_python_module_pythons}
Name: python-djangorestframework-simplejwt
Version: 5.3.1
Version: 5.5.1
Release: 0
Summary: JSON Web Token authentication for Django REST Framework
License: MIT
URL: https://github.com/davesque/django-rest-framework-simplejwt
Source: https://files.pythonhosted.org/packages/source/d/djangorestframework-simplejwt/djangorestframework_simplejwt-%{version}.tar.gz
# PATCH-FIX-UPSTREAM https://github.com/jazzband/djangorestframework-simplejwt/pull/769 Fix tests
Patch0: fix-tests.patch
BuildRequires: %{python_module Django}
BuildRequires: %{python_module PyJWT}
BuildRequires: %{python_module cryptography}
BuildRequires: %{python_module djangorestframework}
BuildRequires: %{python_module freezegun}
BuildRequires: %{python_module pip}
@@ -39,6 +38,7 @@ BuildRequires: fdupes
BuildRequires: python-rpm-macros
Requires: python-PyJWT
Requires: python-djangorestframework
Recommends: python-cryptography
Recommends: python-python-jose
BuildArch: noarch
%python_subpackages