-
Notifications
You must be signed in to change notification settings - Fork 205
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
SSL connect/disconnect loop #86
Comments
Hi I have traced back this issue to line #224 on init.py . While setting this timeout don't seem to cause issues the http , using https this would cause socket to be dropped. I'm not sure why is this line here as code is already unblocking recv on _reset_heartbeat. Regards, |
@DantePR, I just tested your code on [email protected] with socketIO-client>=0.6.5 and it seems to work fine now (see #54).
You might want to see if |
I am experiencing something that may be similar:
This happens only with https as far as I can tell, and not all the time. My first question would be no know if that's the same issue or not, the error message being similar but not identical (sslv3 alert bad record mac) Any other angle/tip/comment on this issue would be of tremendous help Thanks in advance PS. I run on macOS 10.12.6 As far as other libs are concerned:
Also I am using the code from the tip at github, where I had to redirect
Here's the complete log from the client side
|
Hi,
I'm experiencing the following only thru ssl , http connections are fine. but when connecting thru ssl I get disconnected saying "WARNING:root:iot.myHost.io:3001/socket.io [connection error] recv disconnected by SSL (('The read operation timed out',))" for every time that I execute socketIO.wait(seconds=1). I have tried running my socket.io server as http and using nginx for the ssl and also running native node https server both have same results. It would be great help any feedback.
BTW SSL works fine for everything else, certificate seems to be good. as I can curl and see correct response.
Im running socketIO-client on python 2.7.9 but it does same on 2.7.3 on raspbian.
socket.io server debug
This is log form socket.io, this is repeated for every socketIO.wait :
App connected
socket.io:socket joining room cloud +1ms
socket.io:socket joined room mGZgzNZ6gsAqycLoAAAF +0ms
socket.io:socket joined room cloud +0ms
engine upgrading existing transport +754ms
engine:socket might upgrade socket transport from "polling" to "websocket" +0ms
engine:ws received "2probe" +89ms
engine:ws writing "3probe" +0ms
engine:ws received "5" +100ms
engine:socket got upgrade packet - upgrading +0ms
engine:socket flushing buffer to transport +0ms
engine:ws writing "40" +0ms
engine:ws received "2" +1ms
engine:socket packet +0ms
engine:socket got ping +0ms
engine:socket sending packet "pong" (undefined) +0ms
engine:socket flushing buffer to transport +1ms
engine:ws writing "3" +0ms
socket.io:client client close with reason transport close +6s
socket.io:socket closing socket - reason transport close +1ms
socket.io:client ignoring remove for 0SV7_KSjY9OAc79rAAAE +0ms
Cloud App Dissconnected
socket.io:client client close with reason transport close +48ms
socket.io:socket closing socket - reason transport close +1ms
socket.io:client ignoring remove for mGZgzNZ6gsAqycLoAAAF +0ms
Socket.IO server :
var fs = require('fs');
var options = {
key: fs.readFileSync('/opt/certs/iot.myhost.io.key'),
cert: fs.readFileSync('/opt/certs/iot.myhost.io.chained.crt')
};
var app = require('https').createServer(options,handler)
var io = require('socket.io')(app);
app.listen(3001);
Python raspbian client
socketIO = SocketIO('https://iot.myhost.io,3001, params={"myID":'898989898',"type":"CLIENT"})
socketIO.on('on_test', on_test_response)
socketIO.wait(seconds=1)
Thanks,
Ray
The text was updated successfully, but these errors were encountered: