-
Notifications
You must be signed in to change notification settings - Fork 3k
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
[SocketIOUser] - I have provided the code to turn off the SSL certification but still, I'm getting an SSL certification error #2144
Comments
I'm using the below version, - locust 2.10.1 |
open() is pretty much just a wrapper around websocket.create_connection(), so maybe check its documentation? |
Hi @cyberw, I don't see open() in a WebSocket class. And I don't see it's documented anywhere. WebSocket.create_connection() is accepting the sslopt parameters (Refer the highlighted lines below) but SocketIOUser.connect() is not accepting the sslopt. Getting the below error message when I pass the sslopt parameters TypeError: SocketIOUser.connect() got an unexpected keyword argument 'sslopt' def create_connection(url, timeout=None, class_=WebSocket, **options): Please note: I'm able to run my code with websocket.create_connection() not with SocketIOUser.connect() Kindly change the code to accept sslopt and subprotocols as well. |
Sorry, I meant connect, not open. |
If you want to change it to also forward other arguments, please make a PR. |
Based on the comments from @cyberw, I have fixed the issue - locustio/locust#2144. Please find the below code for the file - locust-plugins/locust_plugins/users/socketio.py. Please review and commit the code accordingly.
Hi @cyberw, I have raised the PR. Please review and merge the code. |
Fixed in locust-plugins 2.6.9 |
Hi All,
I have provided the code to turn off the SSL certification but still, I'm getting an SSL certification error. Please find the below code -
class TestLocust(SocketIOUser):
Error Message:
ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: certificate has expired (_ssl.c:997)
Any help or suggestion would be appreciated. Thanks in advance.
The text was updated successfully, but these errors were encountered: