Skip to content

Commit 0be9cb2

Browse files
committed
Set maxAge idle session to four (4) hours
* This can be tweaked to slightly larger but the default of two weeks server side is too much. Sync both client access and server expiration to this value. * Going to bump all stored sessions in a few moments Related to OpenUserJS#604
1 parent f4bd642 commit 0be9cb2

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

app.js

+3-1
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,9 @@ app.use(session({
289289
resave: false,
290290
saveUninitialized: false,
291291
unset: 'destroy',
292-
cookie: { maxAge: null },
292+
cookie: {
293+
maxAge: 4 * 60 * 60 * 1000 // 4 hours in ms
294+
},
293295
secret: sessionSecret,
294296
store: sessionStore
295297
}));

0 commit comments

Comments
 (0)