2
0
mirror of https://github.com/xcat2/confluent.git synced 2024-11-26 03:19:48 +00:00

Point to the C context object rather than python class

The OpenSSL variant of Context is a python class, but it does have
a C context in it.
This commit is contained in:
Jarrod Johnson 2024-07-25 14:05:10 -04:00
parent c3e918fc5f
commit 298be3b30a

View File

@ -431,7 +431,7 @@ def _tlsstartup(cnn):
ctx.use_certificate_file('/etc/confluent/srvcert.pem')
ctx.use_privatekey_file('/etc/confluent/privkey.pem')
ctx.set_verify(libssln.VERIFY_PEER, lambda *args: True)
ssl_ctx = PySSLContext.from_address(id(ctx)).ctx
ssl_ctx = PySSLContext.from_address(id(ctx._context)).ctx
libsslc.SSL_CTX_set_cert_verify_callback(ssl_ctx, verify_stub, 0)
cnn = libssl.Connection(ctx, cnn)
cnn.set_accept_state()