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

Passing cookies during handshake #1840

Closed
ggrav opened this issue Oct 24, 2014 · 6 comments
Closed

Passing cookies during handshake #1840

ggrav opened this issue Oct 24, 2014 · 6 comments

Comments

@ggrav
Copy link

ggrav commented Oct 24, 2014

My deployment environment provides sticky connection via a Cookie parameter which is got when the first get request is made to the server. The subsequent request needs to pass the cookie for providing the sticky connection.

I verified that The cookies are getting passed correctly when running the client in the browser. However, the cookie information is not coming to the server , if I run the client code as a node.exe process

Below is my stripped down version of the client code. Any idea on how I can pass the cookie information ?

var io = require("socket.io-client");

var socket = io.connect(http://bubble.trafficmanager.net/, { 'force new connection' : true });

socket.on('connect', function () {
});

@ggrav
Copy link
Author

ggrav commented Oct 30, 2014

hi - Any pointers will be really helpful

@klimashkin
Copy link

You mean pass cookie from one nodejs process (client) to another (server) during socket.io handshake ?

@peteruithoven
Copy link

It's quite troublesome to use cookies from a nodejs proces. I ended up using a url parameter, see:
socketio/socket.io-client#775

@ggrav
Copy link
Author

ggrav commented Nov 6, 2014

klimashkin - yes , this is from the client to another server. I am trying to build an IPhone app using SIOSocket. the issue happens there as well..

peteruithoven - I am using azure websites as the platform where sticky session is supported by the platform. I do not control it. I will have to move to cloud service and implement my own ARR - If there is no way to do it, I will have to explore this :(

@peteruithoven
Copy link

What's ARR?
Maybe you can investigate whether Azure supports url parameters or ip based sticky sessions?

@darrachequesne
Copy link
Member

That issue was closed automatically. Please check if your issue is fixed with the latest release, and reopen if needed (with a fiddle reproducing the issue if possible).

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

4 participants