You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm sorry if it's a dupliacate to my last comment @ #1286 , but i saw that issue is closed. Yet i seem to have that issue using the latest version, despite it's supposed to be fixed.
I've updated express (both for the local project and globaly),
I'm still having the prefix bug: my code https://gist.github.com/3397357
express v: 3.0.0rc3
node 0.8.7
some more info, with DEBUG=connect:redis
connect:redis SETEX "sess:IdsW2EYeX0AZIowXELobsZeT" ttl:{"cookie":{"originalMaxAge":null,"expires":null,"httpOnly":true,"path":"/"}} %s +0ms
connect:redis SETEX complete +4ms
printing the handshake data (console.log(handshakeData.headers);)
gives: { host: 'local .... '
....
"cookie":"connect.sid=s%3AIdsW2EYeX0AZIowXELobsZeT.ZgA%2FNixR6ZRMnHS8gga2kSYS%2FYhOAupTtQKUAxXP%2BbM"}
and then when a get from redis happends (it looks for "sess:s:.... instead of sess:Id...")
connect:redis GET "sess:s:IdsW2EYeX0AZIowXELobsZeT.ZgA/NixR6ZRMnHS8gga2kSYS/YhOAupTtQKUAxXP+bM" +5s
keys in redis:
"sess:IdsW2EYeX0AZIowXELobsZeT"
Thank you and sorry for duplicating post.
The text was updated successfully, but these errors were encountered:
I think this is behaving properly and is due to you passing an unparsed signed cookie to sessionStore.get.
On line 9 of your gist, it looks like you parse req_cookie['connect.sid'] and store it in req_session, but on line 11 you pass the unparsed cookie req_cookie['connect.sid'] instead.
Thanks for your help (i was playing with it so much i must have missed it..) .
One tip to give:
sessionStore.get('' + req_session, function(err, session) {
else error will occur.
One more thing if you (or anyone else) , will
From the moment redis found your key (thus active session), how do you tell express, yes we have here a session:
as you can see i've tried various thing (line 13-34), one place i did: handshakeData.session = new Session(data, session);
the other: session = new express.session.Session(req, session); (is this synchronous? )
what's the best practiced way to use the new express ?
I'm sorry if it's a dupliacate to my last comment @ #1286 , but i saw that issue is closed. Yet i seem to have that issue using the latest version, despite it's supposed to be fixed.
I've updated express (both for the local project and globaly),
I'm still having the prefix bug: my code https://gist.github.com/3397357
express v: 3.0.0rc3
node 0.8.7
some more info, with DEBUG=connect:redis
connect:redis SETEX "sess:IdsW2EYeX0AZIowXELobsZeT" ttl:{"cookie":{"originalMaxAge":null,"expires":null,"httpOnly":true,"path":"/"}} %s +0ms
connect:redis SETEX complete +4ms
printing the handshake data (console.log(handshakeData.headers);)
gives: { host: 'local .... '
....
"cookie":"connect.sid=s%3AIdsW2EYeX0AZIowXELobsZeT.ZgA%2FNixR6ZRMnHS8gga2kSYS%2FYhOAupTtQKUAxXP%2BbM"}
and then when a get from redis happends (it looks for "sess:s:.... instead of sess:Id...")
connect:redis GET "sess:s:IdsW2EYeX0AZIowXELobsZeT.ZgA/NixR6ZRMnHS8gga2kSYS/YhOAupTtQKUAxXP+bM" +5s
keys in redis:
Thank you and sorry for duplicating post.
The text was updated successfully, but these errors were encountered: