Encryptors 2.76__tar.gz → 2.77__tar.gz
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.
- {encryptors-2.76 → encryptors-2.77}/PKG-INFO +1 -1
- {encryptors-2.76 → encryptors-2.77}/setup.py +1 -1
- {encryptors-2.76 → encryptors-2.77}/src/Encryptors.egg-info/PKG-INFO +1 -1
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Models/TokenClaims.py +19 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Services/__init__.py +3 -2
- {encryptors-2.76 → encryptors-2.77}/README.md +0 -0
- {encryptors-2.76 → encryptors-2.77}/setup.cfg +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Encryptors.egg-info/SOURCES.txt +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Encryptors.egg-info/dependency_links.txt +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Encryptors.egg-info/entry_points.txt +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Encryptors.egg-info/requires.txt +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Encryptors.egg-info/top_level.txt +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Cache/Redis.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Cache/__init__.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Cli/__init__.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Constants/Constant.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Constants/Message.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Constants/__init__.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Context/__init__.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Database/BaseRepository.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Database/Connection.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Database/__init__.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Decorators/Grpc.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Decorators/Retry.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Decorators/SecureResolver.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Decorators/__init__.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Encryptor/Aes.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Encryptor/Argon2.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Encryptor/Bcrypt.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Encryptor/Jwt.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Encryptor/Rsa.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Encryptor/Sha512.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Encryptor/__init__.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Enums/AuditType.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Enums/CipherType.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Enums/FileType.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Enums/GrahpqlOperation.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Enums/GrpcStatusCode.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Enums/Profile.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Enums/ResultType.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Enums/Secret.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Enums/StatusCode.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Enums/__init__.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Exception/ControlledException.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Exception/__init__.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Helpers/AuditHelper.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Helpers/AuditQueue.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Helpers/AuthTokenProcessor.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Helpers/AzureClassifier.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Helpers/CipherHelper.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Helpers/JwtTokenHelper.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Helpers/Resilience.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Helpers/__init__.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Http/APIClient.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Http/__init__.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Messaging/AzureServiceBus.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Messaging/Kafka.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Messaging/RabbitMQ.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Messaging/__init__.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Models/ApiResponse.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Models/AuditContext.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Models/Graphql.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Models/Notification.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Models/Response.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Models/Token.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Models/__init__.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Secrets/AzureKeyVaultProvider.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Secrets/__init__.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Services/GrpcConnection.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Services/JwtAuthTokenService.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Services/ServiceBusAuditEmitter.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Services/WebsocketClient.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Storage/AzureBlobStorage.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Storage/S3Storage.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Storage/__init__.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Utils/CaseConverter.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Utils/CodeGenerator.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Utils/DataNormalizer.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Utils/DataUtils.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Utils/DateUtils.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Utils/FileMetaData.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Utils/HashValidator.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Utils/Mapper.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Utils/PasswordGenerator.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Utils/QueryGenerator.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Utils/RsaUtils.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Utils/TextProcessor.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/Utils/__init__.py +0 -0
- {encryptors-2.76 → encryptors-2.77}/src/Osdental/__init__.py +0 -0
|
@@ -77,4 +77,23 @@ class ActionTokenClaims(BaseClaims):
|
|
|
77
77
|
return cls(
|
|
78
78
|
sub=claims["sub"],
|
|
79
79
|
action=claims["action"],
|
|
80
|
+
)
|
|
81
|
+
|
|
82
|
+
|
|
83
|
+
@dataclass(frozen=True, slots=True)
|
|
84
|
+
class ExternalTokenClaims(BaseClaims):
|
|
85
|
+
|
|
86
|
+
user_key: str
|
|
87
|
+
password: str
|
|
88
|
+
enterprise_key: str
|
|
89
|
+
id_authorization: str
|
|
90
|
+
|
|
91
|
+
@classmethod
|
|
92
|
+
def from_dict(cls, claims: dict):
|
|
93
|
+
|
|
94
|
+
return cls(
|
|
95
|
+
user_key=claims["user_key"],
|
|
96
|
+
password=claims["password"],
|
|
97
|
+
enterprise_key=claims["enterprise_key"],
|
|
98
|
+
id_authorization=claims["id_authorization"],
|
|
80
99
|
)
|
|
@@ -16,13 +16,14 @@ class INotificationPublisher(ABC):
|
|
|
16
16
|
class IAuthTokenService(ABC):
|
|
17
17
|
|
|
18
18
|
from Osdental.Models.TokenClaims import (
|
|
19
|
-
|
|
19
|
+
BaseClaims, AccessTokenClaims,
|
|
20
|
+
UserTokenClaims, ActionTokenClaims
|
|
20
21
|
)
|
|
21
22
|
|
|
22
23
|
@abstractmethod
|
|
23
24
|
async def generate_token(
|
|
24
25
|
self,
|
|
25
|
-
claims:
|
|
26
|
+
claims: BaseClaims,
|
|
26
27
|
expires_at: datetime,
|
|
27
28
|
) -> str:
|
|
28
29
|
pass
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|