UPDATE: It's worth mentioning, my website is being loaded via an iframe.
Here's my cookieSession in my app.js:
app.use(cookieParser());
app.use(cookieSession({
secret: "SECRET_SIGNING_KEY",
maxAge: 15724800000
}));
I then try to set the user, and token when logging in.
app.post('/login', function(req, res){
Parse.User.logIn(req.body.username, req.body.password).then(function(user) {
req.session.user = user;
req.session.token = user.getSessionToken();
res.redirect('/dashboard');
}, function(error) {
console.log(error)
req.session = null;
res.render('login');
});
});
This works in Chrome but it doesn't work in Safari.
I've checked the Safari storage via the web console and under my domain there is nothing being saved.
Any reason why it's not working?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…