qubesd: fix response message header

Type is not 16 bit big-endian. Encode it as 8bit code and \x00 as
delimiter explicitly.

QubesOS/qubes-issues#853
This commit is contained in:
Marek Marczykowski-Górecki 2017-02-27 21:43:14 +01:00
parent 6ab7032b11
commit 2169075807
No known key found for this signature in database
GPG Key ID: 063938BA42CFA724

View File

@ -19,7 +19,7 @@ QUBESD_SOCK = '/var/run/qubesd.sock'
class QubesDaemonProtocol(asyncio.Protocol):
buffer_size = 65536
header = struct.Struct('!H')
header = struct.Struct('Bx')
def __init__(self, *args, app, debug=False, **kwargs):
super().__init__(*args, **kwargs)