balderdashy / sails

Realtime MVC Framework for Node.js
https://sailsjs.com
MIT License
22.84k stars 1.95k forks source link

Many empty session entries generated #6995

Open LouAdrien opened 4 years ago

LouAdrien commented 4 years ago

Node version: v12.14.1 "sails": "^1.2.3", "sails-hook-apianalytics": "^2.0.3", "sails-hook-organics": "^0.16.0", "sails-hook-orm": "^2.1.1", "sails-hook-sockets": "^2.0.0", "sails-mongo": "^1.0.1", "sails-postgresql": "^1.0.2",


Hello, I am using connect-mongo as session adapter Any login (which stores a session internally) will generate tones of empty session entires, see attached screenshot is the result of login/logout/login.

Screenshot 2020-05-15 at 17 24 30

I dont see any related issue in mongo-connect so I think this should be a sails issue. Have you ever encountered such problem? This will totally spam my session store.

sailsbot commented 4 years ago

@LouAdrien Thanks for posting! We'll take a look as soon as possible.

In the mean time, there are a few ways you can help speed things along:

Please remember: never post in a public forum if you believe you've found a genuine security vulnerability. Instead, disclose it responsibly.

For help with questions about Sails, click here.

LouAdrien commented 4 years ago

Sidenote : this happen only in dev mode, not production

mikermcneil commented 4 years ago

@LouAdrien Just a hunch- are you using Passport.js?

mikermcneil commented 4 years ago

@LouAdrien Also, can you tell me a bit more about your prod environment and how you're doing SSL? (also the app's sails.config.session.cookie.ssl and sails.config.http.trustProxy settings in dev vs. prod) Thanks!