pep8
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Torma Kristóf 2021-04-24 23:41:34 +02:00
parent 281af0fb2e
commit 9dc4cab674
Signed by: tormakris
GPG Key ID: DC83C4F2C41B1047

View File

@ -69,7 +69,8 @@ class NetWrapper:
ciphertext = cipher.encrypt(message)
nonce = b64encode(cipher.nonce).decode('UTF-8')
ct = b64encode(ciphertext).decode('UTF-8')
sendjson = json.dumps({'type': 'AUT', 'source': self.network.own_addr, 'nonce': nonce, 'message': ct}).encode('UTF-8')
sendjson = json.dumps({'type': 'AUT', 'source': self.network.own_addr, 'nonce': nonce, 'message': ct}).encode(
'UTF-8')
self.network.send_msg(self.serverAddr, sendjson)
status, msg = self.network.receive_msg(blocking=True)
if not status:
@ -99,7 +100,8 @@ class NetWrapper:
ciphertext = cipher.encrypt(message)
nonce = b64encode(cipher.nonce).decode('UTF-8')
ct = b64encode(ciphertext).decode('UTF-8')
sendjson = json.dumps({'type': 'CMD', 'source': self.network.own_addr, 'nonce': nonce, 'message': ct}).encode('UTF-8')
sendjson = json.dumps({'type': 'CMD', 'source': self.network.own_addr, 'nonce': nonce, 'message': ct}).encode(
'UTF-8')
self.network.send_msg(self.serverAddr, sendjson)
def recieveMessage(self) -> bytes: