Mehdi Chibouni
Mehdi Chibouni

Reputation: 340

Swap/Dump session data using passport.js

I am using Passport for my MEAN stack-based app, that makes use of several APIs that require several OAuth tokens. Because logging in and out causes too much overhead, I am considering to put serialized session data in a Redis store then swap back and forth between existing sessions.

So my question is, is there a way to programmatically extract and/or replace passport data ?

Upvotes: 0

Views: 138

Answers (1)

Hamish McNeill
Hamish McNeill

Reputation: 397

You could try storing the information in MongoDB by using serializeUser() and get it back using deserializeUser()?

Upvotes: 1

Related Questions