from Cryptodome.Hash import SHA3_256 as sha


class AESKey:
    def __init__(self, iv: str, key: str):
        self._iv: bytes = sha.new().update(iv.encode()).digest()[0:16]
        self._key: bytes = sha.new().update(key.encode()).digest()

    @property
    def IV(self) -> bytes:
        return self._iv

    @property
    def key(self) -> bytes:
        return self._key

from Cryptodome.Hash import SHA3_256 as sha


class AESKey:
    def __init__(self, iv: str, key: str):
        self._iv: bytes = sha.new().update(iv.encode()).digest()[0:16]
        self._key: bytes = sha.new().update(key.encode()).digest()

    @property
    def IV(self) -> bytes:
        return self._iv

    @property
    def key(self) -> bytes:
        return self._key
