def METHOD_NAME(encrypted_cipher_text: bytes, secret: model.secret.SecretData):
    if (cipher_alg := secret.cipher_algorithm) is model.secret.Cipher.PLAINTEXT:
        return encrypted_cipher_text
    elif cipher_alg is model.secret.Cipher.AES_ECB:
        pass
    else:
        raise NotImplementedError(cipher_alg)
    from Crypto.Cipher import AES
    cipher = AES.new(key=secret.key, mode=AES.MODE_ECB)
    decrypted_cipher = cipher.decrypt(encrypted_cipher_text)
    try:
        unpadded_cipher = Crypto.Util.Padding.unpad(
            padded_data=decrypted_cipher,
            block_size=AES.block_size,
        )
    except ValueError as ve:
        raise ValueError("Unable to decrypt secret. Key doesn't fit cipher text.") from ve
    return unpadded_cipher