diff --git a/steam/client/cdn.py b/steam/client/cdn.py index b2889d6..f476b9d 100644 --- a/steam/client/cdn.py +++ b/steam/client/cdn.py @@ -223,22 +223,18 @@ class CDNClient(object): data = symmetric_decrypt(resp.content, self.get_depot_key(app_id, depot_id)) if data[:2] == b'VZ': + if data[-2:] != b'zv': + raise ValueError("VZ: Invalid footer: %s" % repr(data[-2:])) if data[2:3] != b'a': - raise ValueError("Invalid VZ version: %s" % repr(data[2:3])) + raise ValueError("VZ: Invalid version: %s" % repr(data[2:3])) vzfilter = lzma._decode_filter_properties(lzma.FILTER_LZMA1, data[7:12]) vzdec = lzma.LZMADecompressor(lzma.FORMAT_RAW, filters=[vzfilter]) - checksum, decompressed_size, vz_footer = struct.unpack('