Browse Source

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
Marek Marczykowski-Górecki 7 years ago
parent
commit
2169075807
1 changed files with 1 additions and 1 deletions
  1. 1 1
      qubes/tools/qubesd.py

+ 1 - 1
qubes/tools/qubesd.py

@@ -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)