Browse Source

fix #23; protocol_version=65579 and gzip decomp

pull/34/head
Rossen Georgiev 9 years ago
parent
commit
947b93c6fe
  1. 2
      steam/client/__init__.py
  2. 5
      steam/core/cm.py

2
steam/client/__init__.py

@ -351,7 +351,7 @@ class SteamClient(EventEmitter, FeatureBase):
message = MsgProto(EMsg.ClientLogon)
message.header.steamid = SteamID(type='Individual', universe='Public')
message.body.protocol_version = 65575
message.body.protocol_version = 65579
message.body.client_package_version = 1771
message.body.client_os_type = EOSType.Win10
message.body.client_language = "english"

5
steam/core/cm.py

@ -1,7 +1,7 @@
import struct
import binascii
import logging
import zipfile
from gzip import GzipFile
from time import time
from collections import defaultdict
@ -290,7 +290,8 @@ class CMClient(EventEmitter):
if msg.body.size_unzipped:
logger.debug("Unzipping body")
data = zipfile.ZipFile(BytesIO(msg.body.message_body)).read('z')
with GzipFile(fileobj=BytesIO(msg.body.message_body)) as f:
data = f.read()
if len(data) != msg.body.size_unzipped:
logger.fatal("Unzipped size mismatch")

Loading…
Cancel
Save