Skip to content

Commit

Permalink
Adds secureProxy to manage SSL proxied connections on no Express Node…
Browse files Browse the repository at this point in the history
… servers
  • Loading branch information
PixelsCommander committed Sep 1, 2020
1 parent 8cf0508 commit fcaea7c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion index.js
Expand Up @@ -45,6 +45,7 @@ function cookieSession (options) {
var name = opts.name || 'session'

// secrets
var secureProxy = opts.secureProxy || false;
var keys = opts.keys
if (!keys && opts.secret) keys = [opts.secret]

Expand All @@ -59,7 +60,8 @@ function cookieSession (options) {

return function _cookieSession (req, res, next) {
var cookies = new Cookies(req, res, {
keys: keys
keys: keys,
secure: secureProxy,
})
var sess

Expand Down

0 comments on commit fcaea7c

Please sign in to comment.