Commit 024b81c0 by Oleksandr Barabash

syntax fix

parent 5ac94a78
......@@ -2,7 +2,7 @@
import asyncio
import random
from concurrent.futures.thread import ThreadPoolExecutor
from typing import Awaitable, Coroutine
from typing import Awaitable
# noinspection PyPackageRequirements
from azure.keyvault.keys import KeyClient, KeyVaultKey
......@@ -84,10 +84,10 @@ class AzureKeyVaultClient:
result = cipher.decrypt(EncryptionAlgorithm.rsa_oaep, data)
return result.plaintext
def encrypt(self, key: KeyVaultKey, data: bytes) -> Coroutine[bytes]:
def encrypt(self, key: KeyVaultKey, data: bytes) -> Awaitable[bytes]:
""" Encrypt data """
return self.execute_blocking(self.encrypt_bl, key, data)
def decrypt(self, key: KeyVaultKey, data: bytes) -> Coroutine[bytes]:
""" Encrypt data """
def decrypt(self, key: KeyVaultKey, data: bytes) -> Awaitable[bytes]:
""" Decrypt data """
return self.execute_blocking(self.decrypt_bl, key, data)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment