Skip to content
This repository has been archived by the owner on Aug 13, 2024. It is now read-only.

Improve error handling when client trying to connect using SSL and the server is not using SSL #18

Open
saidelike opened this issue Dec 20, 2019 · 0 comments
Labels
bug Something isn't working

Comments

@saidelike
Copy link
Collaborator

Atm the server shows:

[ERROR] (10.131.108.194:37519) Expecting value: line 1 column 1 (char 0)
Traceback (most recent call last):
  File "/home/user/IDArling/idarling/shared/sockets.py", line 199, in _notify_read
    dct = json.loads(line.decode("utf-8"))
  File "/usr/lib/python3.6/json/__init__.py", line 354, in loads
    return _default_decoder.decode(s)
  File "/usr/lib/python3.6/json/decoder.py", line 339, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/lib/python3.6/json/decoder.py", line 357, in raw_decode
    raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
[WARNING] (10.131.108.194:37519) Invalid packet received: bytearray(b'\x00\x1d\x00\x17\x00\x1e\x00\x19\x00\x18\x00#\x00\x00\x00\x16\x00\x00\x00\x17\x00\x00\x00\r\x000\x00.\x04\x03\x05\x03\x06\x03\x08\x07\x08\x08\x08\t\x08')
[ERROR] (10.131.108.194:37519) Expecting value: line 1 column 1 (char 0)

And the client does not show any error and just hangs on "connecting..."

So we need better error handling

@saidelike saidelike added the bug Something isn't working label Feb 24, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant