Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not able to connect using secure=True #22

Open
deepaknairrpf opened this issue Aug 26, 2021 · 0 comments
Open

Not able to connect using secure=True #22

deepaknairrpf opened this issue Aug 26, 2021 · 0 comments

Comments

@deepaknairrpf
Copy link

Getting the below exception when passing secure=True as follows:

    conn = await connect(
        host="<HOST>",
        port=9440,
        database="<DB>",
        user="<USER>",
        password="<PASSWORD>", secure=True
    )

  File "/home/deebug/PycharmProjects/pythonProject/asyncch_test.py", line 27, in <module>
    asyncio.run(connect_database())
  File "/home/deebug/miniconda3/lib/python3.7/asyncio/runners.py", line 43, in run
    return loop.run_until_complete(main)
  File "/home/deebug/miniconda3/lib/python3.7/asyncio/base_events.py", line 587, in run_until_complete
    return future.result()
  File "/home/deebug/PycharmProjects/pythonProject/asyncch_test.py", line 11, in connect_database
    password="<PASSWORD>", secure=True
  File "/home/deebug/PycharmProjects/pythonProject/venv3.7/lib/python3.7/site-packages/asynch/connection.py", line 199, in connect
    await conn.connect()
  File "/home/deebug/PycharmProjects/pythonProject/venv3.7/lib/python3.7/site-packages/asynch/connection.py", line 97, in connect
    await self._connection.connect()
  File "/home/deebug/PycharmProjects/pythonProject/venv3.7/lib/python3.7/site-packages/asynch/proto/connection.py", line 470, in connect
    return await self._init_connection(host, port)
  File "/home/deebug/PycharmProjects/pythonProject/venv3.7/lib/python3.7/site-packages/asynch/proto/connection.py", line 457, in _init_connection
    await self.receive_hello()
  File "/home/deebug/PycharmProjects/pythonProject/venv3.7/lib/python3.7/site-packages/asynch/proto/connection.py", line 199, in receive_hello
    packet_type = await self.reader.read_varint()
  File "/home/deebug/PycharmProjects/pythonProject/venv3.7/lib/python3.7/site-packages/asynch/proto/io.py", line 127, in read_varint
    packet = self._read_one()
  File "/home/deebug/PycharmProjects/pythonProject/venv3.7/lib/python3.7/site-packages/asynch/proto/io.py", line 117, in _read_one
    packet = self.buffer[self.position]
IndexError: bytearray index out of range

Can you please provide a documentation or an example involving connecting using SSL?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant