pypomes-jwt 1.3.3__py3-none-any.whl → 1.3.4__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of pypomes-jwt might be problematic. Click here for more details.
- pypomes_jwt/jwt_registry.py +9 -9
- {pypomes_jwt-1.3.3.dist-info → pypomes_jwt-1.3.4.dist-info}/METADATA +1 -1
- {pypomes_jwt-1.3.3.dist-info → pypomes_jwt-1.3.4.dist-info}/RECORD +5 -5
- {pypomes_jwt-1.3.3.dist-info → pypomes_jwt-1.3.4.dist-info}/WHEEL +0 -0
- {pypomes_jwt-1.3.3.dist-info → pypomes_jwt-1.3.4.dist-info}/licenses/LICENSE +0 -0
pypomes_jwt/jwt_registry.py
CHANGED
|
@@ -203,8 +203,8 @@ class JwtRegistry:
|
|
|
203
203
|
|
|
204
204
|
# may raise an exception
|
|
205
205
|
return jwt.encode(payload=current_claims,
|
|
206
|
-
key=JwtConfig.ENCODING_KEY
|
|
207
|
-
algorithm=JwtConfig.DEFAULT_ALGORITHM
|
|
206
|
+
key=JwtConfig.ENCODING_KEY,
|
|
207
|
+
algorithm=JwtConfig.DEFAULT_ALGORITHM,
|
|
208
208
|
headers={"kid": nature})
|
|
209
209
|
|
|
210
210
|
def issue_tokens(self,
|
|
@@ -258,8 +258,8 @@ class JwtRegistry:
|
|
|
258
258
|
current_claims["exp"] = just_now + account_data.get("refresh-max-age")
|
|
259
259
|
# may raise an exception
|
|
260
260
|
refresh_token: str = jwt.encode(payload=current_claims,
|
|
261
|
-
key=JwtConfig.ENCODING_KEY
|
|
262
|
-
algorithm=JwtConfig.DEFAULT_ALGORITHM
|
|
261
|
+
key=JwtConfig.ENCODING_KEY,
|
|
262
|
+
algorithm=JwtConfig.DEFAULT_ALGORITHM,
|
|
263
263
|
headers={"kid": "R0"})
|
|
264
264
|
|
|
265
265
|
# make sure to have a database connection
|
|
@@ -275,8 +275,8 @@ class JwtRegistry:
|
|
|
275
275
|
logger=logger)
|
|
276
276
|
# issue the definitive refresh token
|
|
277
277
|
refresh_token = jwt.encode(payload=current_claims,
|
|
278
|
-
key=JwtConfig.ENCODING_KEY
|
|
279
|
-
algorithm=JwtConfig.DEFAULT_ALGORITHM
|
|
278
|
+
key=JwtConfig.ENCODING_KEY,
|
|
279
|
+
algorithm=JwtConfig.DEFAULT_ALGORITHM,
|
|
280
280
|
headers={"kid": f"R{token_id}"})
|
|
281
281
|
# persist it
|
|
282
282
|
db_update(update_stmt=f"UPDATE {JwtDbConfig.TABLE}",
|
|
@@ -305,8 +305,8 @@ class JwtRegistry:
|
|
|
305
305
|
current_claims["exp"] = just_now + account_data.get("access-max-age")
|
|
306
306
|
# may raise an exception
|
|
307
307
|
access_token: str = jwt.encode(payload=current_claims,
|
|
308
|
-
key=JwtConfig.ENCODING_KEY
|
|
309
|
-
algorithm=JwtConfig.DEFAULT_ALGORITHM
|
|
308
|
+
key=JwtConfig.ENCODING_KEY,
|
|
309
|
+
algorithm=JwtConfig.DEFAULT_ALGORITHM,
|
|
310
310
|
headers={"kid": f"A{token_id}"})
|
|
311
311
|
# return the token data
|
|
312
312
|
return {
|
|
@@ -438,7 +438,7 @@ class JwtRegistry:
|
|
|
438
438
|
JwtDbConfig.COL_ACCOUNT: account_id,
|
|
439
439
|
JwtDbConfig.COL_TOKEN: jwt_token,
|
|
440
440
|
JwtDbConfig.COL_ALGORITHM:
|
|
441
|
-
JwtConfig.DEFAULT_ALGORITHM
|
|
441
|
+
JwtConfig.DEFAULT_ALGORITHM,
|
|
442
442
|
JwtDbConfig.COL_DECODER:
|
|
443
443
|
b64encode(s=JwtConfig.DECODING_KEY.value).decode()
|
|
444
444
|
},
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: pypomes_jwt
|
|
3
|
-
Version: 1.3.
|
|
3
|
+
Version: 1.3.4
|
|
4
4
|
Summary: A collection of Python pomes, penyeach (JWT module)
|
|
5
5
|
Project-URL: Homepage, https://github.com/TheWiseCoder/PyPomes-JWT
|
|
6
6
|
Project-URL: Bug Tracker, https://github.com/TheWiseCoder/PyPomes-JWT/issues
|
|
@@ -2,8 +2,8 @@ pypomes_jwt/__init__.py,sha256=vXAeaEnuUqpvGtV465TsW2Lf3ihijrMP2Hm4My79y88,968
|
|
|
2
2
|
pypomes_jwt/jwt_config.py,sha256=74MFwU5gDx9c1_OHFcFMY-AyD-yqnBQGY6Y2JkkslwQ,3525
|
|
3
3
|
pypomes_jwt/jwt_pomes.py,sha256=WWmZYVpG6wqlIjcJU3jNyBquCgfB-OcgCJBmm6imL4Q,23524
|
|
4
4
|
pypomes_jwt/jwt_providers.py,sha256=LL2OxdyGH3_O-qEOVjg_GsPQVRtaSi37AE-BOZ6tiqs,5928
|
|
5
|
-
pypomes_jwt/jwt_registry.py,sha256=
|
|
6
|
-
pypomes_jwt-1.3.
|
|
7
|
-
pypomes_jwt-1.3.
|
|
8
|
-
pypomes_jwt-1.3.
|
|
9
|
-
pypomes_jwt-1.3.
|
|
5
|
+
pypomes_jwt/jwt_registry.py,sha256=TuIbnAUlYyFcP8DD7dyViNn49N6NoaEp8bBfDkW29_k,22577
|
|
6
|
+
pypomes_jwt-1.3.4.dist-info/METADATA,sha256=h3KzUz2C1AveXub-T-GwWyAOaxvkjat-P4VMMLx5vu4,660
|
|
7
|
+
pypomes_jwt-1.3.4.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
8
|
+
pypomes_jwt-1.3.4.dist-info/licenses/LICENSE,sha256=NdakochSXm_H_-DSL_x2JlRCkYikj3snYYvTwgR5d_c,1086
|
|
9
|
+
pypomes_jwt-1.3.4.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|