|
|
@@ -24,7 +24,7 @@ class LORANode(object): |
|
|
|
self.st = Strobe(domain) |
|
|
|
|
|
|
|
async def start(self): |
|
|
|
msg = self.st.send_enc(b'reqreset' + os.urandom(16)) + \ |
|
|
|
msg = self.st.send_enc(os.urandom(16) + b'reqreset') + \ |
|
|
|
self.st.send_mac(8) |
|
|
|
|
|
|
|
resp = await self.sd.sendtillrecv(msg, 1) |
|
|
@@ -182,7 +182,7 @@ class TestLORANode(unittest.IsolatedAsyncioTestCase): |
|
|
|
pkt = l.recv_enc(r[:-8]) |
|
|
|
l.recv_mac(r[-8:]) |
|
|
|
|
|
|
|
assert pkt.startswith(b'reqreset') |
|
|
|
assert pkt.endswith(b'reqreset') |
|
|
|
|
|
|
|
await self.put(l.send_enc(os.urandom(16)) + |
|
|
|
l.send_mac(8)) |
|
|
|