pypomes-jwt 1.3.6__py3-none-any.whl → 1.3.7__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_config.py +15 -7
- pypomes_jwt/jwt_providers.py +4 -5
- {pypomes_jwt-1.3.6.dist-info → pypomes_jwt-1.3.7.dist-info}/METADATA +1 -2
- pypomes_jwt-1.3.7.dist-info/RECORD +9 -0
- pypomes_jwt-1.3.6.dist-info/RECORD +0 -9
- {pypomes_jwt-1.3.6.dist-info → pypomes_jwt-1.3.7.dist-info}/WHEEL +0 -0
- {pypomes_jwt-1.3.6.dist-info → pypomes_jwt-1.3.7.dist-info}/licenses/LICENSE +0 -0
pypomes_jwt/jwt_config.py
CHANGED
|
@@ -66,14 +66,22 @@ del _encoding_key
|
|
|
66
66
|
del _default_algorithm
|
|
67
67
|
|
|
68
68
|
|
|
69
|
+
# database access is not be necessary, if handling only externally provided JWT tokens
|
|
69
70
|
class JwtDbConfig(StrEnum):
|
|
70
71
|
"""
|
|
71
72
|
Parameters for JWT database connection.
|
|
72
73
|
"""
|
|
73
|
-
ENGINE = env_get_str(key=f"{APP_PREFIX}_JWT_DB_ENGINE"
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
74
|
+
ENGINE = env_get_str(key=f"{APP_PREFIX}_JWT_DB_ENGINE",
|
|
75
|
+
def_value="")
|
|
76
|
+
TABLE = env_get_str(key=f"{APP_PREFIX}_JWT_DB_TABLE",
|
|
77
|
+
def_value="")
|
|
78
|
+
COL_ACCOUNT = env_get_str(key=f"{APP_PREFIX}_JWT_DB_COL_ACCOUNT",
|
|
79
|
+
def_value="")
|
|
80
|
+
COL_ALGORITHM = env_get_str(key=f"{APP_PREFIX}_JWT_DB_COL_ALGORITHM",
|
|
81
|
+
def_value="")
|
|
82
|
+
COL_DECODER = env_get_str(key=f"{APP_PREFIX}_JWT_DB_COL_DECODER",
|
|
83
|
+
def_value="")
|
|
84
|
+
COL_KID = env_get_str(key=f"{APP_PREFIX}_JWT_DB_COL_KID",
|
|
85
|
+
def_value="")
|
|
86
|
+
COL_TOKEN = env_get_str(key=f"{APP_PREFIX}_JWT_DB_COL_TOKEN",
|
|
87
|
+
def_value="")
|
pypomes_jwt/jwt_providers.py
CHANGED
|
@@ -4,7 +4,6 @@ from base64 import b64encode
|
|
|
4
4
|
from datetime import datetime
|
|
5
5
|
from logging import Logger
|
|
6
6
|
from pypomes_core import TZ_LOCAL, exc_format
|
|
7
|
-
from requests import Response
|
|
8
7
|
from typing import Any
|
|
9
8
|
|
|
10
9
|
# structure:
|
|
@@ -103,10 +102,10 @@ def provider_get_token(provider_id: str,
|
|
|
103
102
|
# "refresh_token": <str>,
|
|
104
103
|
# "refresh_expires_in": <number-of-seconds>
|
|
105
104
|
# }
|
|
106
|
-
response: Response = requests.post(url=url,
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
105
|
+
response: requests.Response = requests.post(url=url,
|
|
106
|
+
data=body_data,
|
|
107
|
+
headers=headers_data,
|
|
108
|
+
timeout=None)
|
|
110
109
|
if response.status_code < 200 or response.status_code >= 300:
|
|
111
110
|
# request resulted in error, report the problem
|
|
112
111
|
err_msg = (f"POST '{url}': failed, "
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: pypomes_jwt
|
|
3
|
-
Version: 1.3.
|
|
3
|
+
Version: 1.3.7
|
|
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
|
|
@@ -14,4 +14,3 @@ Requires-Dist: cryptography>=46.0.2
|
|
|
14
14
|
Requires-Dist: flask>=3.1.2
|
|
15
15
|
Requires-Dist: pyjwt>=2.10.1
|
|
16
16
|
Requires-Dist: pypomes-core>=2.7.6
|
|
17
|
-
Requires-Dist: pypomes-db>=2.7.6
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
pypomes_jwt/__init__.py,sha256=vXAeaEnuUqpvGtV465TsW2Lf3ihijrMP2Hm4My79y88,968
|
|
2
|
+
pypomes_jwt/jwt_config.py,sha256=wi3NmUsSAvSXknU1AZd-7h406J4JeBBi9XwPw0VwsAc,4026
|
|
3
|
+
pypomes_jwt/jwt_pomes.py,sha256=WWmZYVpG6wqlIjcJU3jNyBquCgfB-OcgCJBmm6imL4Q,23524
|
|
4
|
+
pypomes_jwt/jwt_providers.py,sha256=iwTUUHJJuIdSJi9n3o2r3YP1nd0BFGL3BO8ET7Y4NNs,5858
|
|
5
|
+
pypomes_jwt/jwt_registry.py,sha256=ypBEoL0I2F08sR2G2VO9wXxVeE252lNzjIAC3FGORhA,22631
|
|
6
|
+
pypomes_jwt-1.3.7.dist-info/METADATA,sha256=hohXdlI9ilzv7dR6rWuRHLF1UAFx2OqbpHk6q5KYvW8,627
|
|
7
|
+
pypomes_jwt-1.3.7.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
8
|
+
pypomes_jwt-1.3.7.dist-info/licenses/LICENSE,sha256=NdakochSXm_H_-DSL_x2JlRCkYikj3snYYvTwgR5d_c,1086
|
|
9
|
+
pypomes_jwt-1.3.7.dist-info/RECORD,,
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
pypomes_jwt/__init__.py,sha256=vXAeaEnuUqpvGtV465TsW2Lf3ihijrMP2Hm4My79y88,968
|
|
2
|
-
pypomes_jwt/jwt_config.py,sha256=GAFrvsCeBUIt2OzO-xLSM6qTe7iehvqrcHlu_CUnGAI,3638
|
|
3
|
-
pypomes_jwt/jwt_pomes.py,sha256=WWmZYVpG6wqlIjcJU3jNyBquCgfB-OcgCJBmm6imL4Q,23524
|
|
4
|
-
pypomes_jwt/jwt_providers.py,sha256=3o48fGZ9W0xwpdivECMb2E3GLdraU-Vh8zRyejbLgpc,5853
|
|
5
|
-
pypomes_jwt/jwt_registry.py,sha256=ypBEoL0I2F08sR2G2VO9wXxVeE252lNzjIAC3FGORhA,22631
|
|
6
|
-
pypomes_jwt-1.3.6.dist-info/METADATA,sha256=bWvYWUMYqc6AecDMkK0p3KxvXRMLZUTEglopfd8pk_A,660
|
|
7
|
-
pypomes_jwt-1.3.6.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
8
|
-
pypomes_jwt-1.3.6.dist-info/licenses/LICENSE,sha256=NdakochSXm_H_-DSL_x2JlRCkYikj3snYYvTwgR5d_c,1086
|
|
9
|
-
pypomes_jwt-1.3.6.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|