Open joelhoward0 opened 9 years ago
I'm not familiar with express-io and I don't understand this code:
app.io.route('check', function(req) {
-- here, req.session is null. req.sessionID is correct, and I can see the session object serialized in my store, but it's not populated on req.
console.log('checking socket');
});
What you should expect after succesful authentication is that the browser can send events to the server, and that the server is listening to those events.
I'm trying to set up Passport socket authentication alongside http authentication, using express.io's built in support for joined socket/http sessions. (express-io uses socket 0.9.16)
I'm not actually sure what I should expect here - after authenticating my socket connection, on subsequent messages, should I expect req[session] to be populated? Should I expect req to have the same passport-added members that http's req has (req.isAuthenticated, req.logout)? If so, I'm not sure what I'm doing wrong. If not, do you have any suggestions on how to make this 'inflation' happen?
Code below. Thanks!
(I don't see any errors)