maleo-foundation 0.1.94__py3-none-any.whl → 0.1.95__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.
@@ -25,14 +25,17 @@ class Backend(AuthenticationBackend):
25
25
  auth = conn.headers["Authorization"]
26
26
  scheme, token = auth.split()
27
27
  if scheme != 'Bearer':
28
- raise AuthenticationError("Authorization scheme must be Bearer token")
28
+ # raise AuthenticationError("Authorization scheme must be Bearer token")
29
+ return Credentials(), User(authenticated=False)
29
30
 
30
31
  decode_token_parameters = MaleoFoundationTokenParametersTransfers.Decode(key=self._keys.public, token=token)
31
32
  decode_token_result = self._maleo_foundation.services.token.decode(parameters=decode_token_parameters)
32
33
  if not decode_token_result.success:
33
- raise AuthenticationError("Invalid Bearer token, unable to decode token")
34
+ # raise AuthenticationError("Invalid Bearer token, unable to decode token")
35
+ return Credentials(), User(authenticated=False)
34
36
  if decode_token_result.data.exp_dt <= datetime.now(tz=timezone.utc):
35
- raise AuthenticationError("Expired Bearer token, request new or refresh token")
37
+ # raise AuthenticationError("Expired Bearer token, request new or refresh token")
38
+ return Credentials(), User(authenticated=False)
36
39
 
37
40
  payload = decode_token_result.data
38
41
  return (
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: maleo_foundation
3
- Version: 0.1.94
3
+ Version: 0.1.95
4
4
  Summary: Foundation package for Maleo
5
5
  Author-email: Agra Bima Yuda <agra@nexmedis.com>
6
6
  License: MIT
@@ -40,7 +40,7 @@ maleo_foundation/managers/client/google/__init__.py,sha256=47DEQpj8HBSa-_TImW-5J
40
40
  maleo_foundation/managers/client/google/base.py,sha256=eIdd6C2BFIu4EyZ1j017VZaJn_nSTPGFftBwQmVAUDA,1366
41
41
  maleo_foundation/managers/client/google/secret.py,sha256=Ski1CHYeA8vjSk2Oc2Pf4CfFrzT_RcA6NEZwza7gM7Y,4464
42
42
  maleo_foundation/managers/client/google/storage.py,sha256=JFqXd9QgusT75KAWyWdin8V6BbbKcbBCrmWDpqg6i3Q,2530
43
- maleo_foundation/middlewares/authentication.py,sha256=qg4BwJ72aHOKyo19II37bafQaV5OFvff173aKRCp54o,3359
43
+ maleo_foundation/middlewares/authentication.py,sha256=hBGaMiCt0CnUw7sg4PZJ3kFJ0OVXvkOR5LhZcz9QUU8,3545
44
44
  maleo_foundation/middlewares/base.py,sha256=g4cg9gIUveK9zbjhwQtkdefhuoSlv9BUWVCFaSlOClw,13303
45
45
  maleo_foundation/middlewares/cors.py,sha256=9uvBvY2N6Vxa9RP_YtESxcWo6Doi6uS0lzAG9iLY7Uc,2288
46
46
  maleo_foundation/models/__init__.py,sha256=AaKehO7c1HyKhoTGRmNHDddSeBXkW-_YNrpOGBu8Ms8,246
@@ -107,7 +107,7 @@ maleo_foundation/utils/loaders/credential/__init__.py,sha256=qopTKvcMVoTFwyRijeg
107
107
  maleo_foundation/utils/loaders/credential/google.py,sha256=deksZXT5wPhEsSMHbZ3x05WHXxCjLDt76Ns-1Tmhp7g,948
108
108
  maleo_foundation/utils/loaders/key/__init__.py,sha256=hVygcC2ImHc_aVrSrOmyedR8tMUZokWUKCKOSh5ctbo,106
109
109
  maleo_foundation/utils/loaders/key/rsa.py,sha256=gDhyX6iTFtHiluuhFCozaZ3pOLKU2Y9TlrNMK_GVyGU,3796
110
- maleo_foundation-0.1.94.dist-info/METADATA,sha256=pluqhekNm5UlR_v9rZBzlv90rRCCGp__eNWSz8ph3Lk,3419
111
- maleo_foundation-0.1.94.dist-info/WHEEL,sha256=DnLRTWE75wApRYVsjgc6wsVswC54sMSJhAEd4xhDpBk,91
112
- maleo_foundation-0.1.94.dist-info/top_level.txt,sha256=_iBos3F_bhEOdjOnzeiEYSrCucasc810xXtLBXI8cQc,17
113
- maleo_foundation-0.1.94.dist-info/RECORD,,
110
+ maleo_foundation-0.1.95.dist-info/METADATA,sha256=c_7w_2V0-8MtnO27MUKZVzRQYfRR9alWLi-KnUWGPm8,3419
111
+ maleo_foundation-0.1.95.dist-info/WHEEL,sha256=DnLRTWE75wApRYVsjgc6wsVswC54sMSJhAEd4xhDpBk,91
112
+ maleo_foundation-0.1.95.dist-info/top_level.txt,sha256=_iBos3F_bhEOdjOnzeiEYSrCucasc810xXtLBXI8cQc,17
113
+ maleo_foundation-0.1.95.dist-info/RECORD,,