Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Hold on, we're currently generating a fresh version of this report
Generated on May 7, 2024 via pnpm

express-session 1.11.3

Simple session middleware for Express
Package summary
Share
5
issues
1
critical severity
license
1
2
high severity
vulnerability
2
1
moderate severity
vulnerability
1
1
low severity
vulnerability
1
3
licenses
10
MIT
1
ISC
1
N/A
Package created
16 Feb 2014
Version published
11 Jun 2015
Maintainers
1
Total deps
12
Direct deps
9
License
MIT

Issues

5

1 critical severity issue

critical
Recommendation: Check the package code and files for license information
via: debug@2.2.0
Collapse
Expand

2 high severity issues

high
Recommendation: Upgrade to version 2.0.0 or later
via: uid-safe@2.0.0
Recommendation: Upgrade to version 2.6.9 or later
via: debug@2.2.0
Collapse
Expand

1 low severity issue

low
Recommendation: Upgrade to version 2.6.9 or later
via: debug@2.2.0
Collapse
Expand

Licenses

MIT License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
sublicense
private-use
Cannot
hold-liable
Must
include-copyright
include-license
10 Packages, Including:
cookie-signature@1.0.6
cookie@0.1.3
crc@3.3.0
debug@2.2.0
depd@1.0.1
express-session@1.11.3
on-headers@1.0.2
parseurl@1.3.3
uid-safe@2.0.0
utils-merge@1.0.0

ISC License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
Cannot
hold-liable
Must
include-copyright
include-license
1 Packages, Including:
base64-url@1.2.1

N/A

N/A
1 Packages, Including:
ms@0.7.1
Disclaimer

This deed highlights only some of the key features and terms of the actual license. It is not a license and has no legal value. You should carefully review all of the terms and conditions of the actual license before using the licensed material.

Sandworm is not a law firm and does not provide legal services. Distributing, displaying, or linking to this deed or the license that it summarizes does not create a lawyer-client or any other relationship.

Direct Dependencies

9
All Dependencies CSV
β“˜ This is a list of express-session 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities
cookie-signature1.0.62.06 kBMIT
prod
cookie0.1.32.77 kBMIT
prod
crc3.3.09.52 kBMIT
prod
debug2.2.010.05 kBMIT
prod
1
1
1
1
depd1.0.18.33 kBMIT
prod
on-headers1.0.23.15 kBMIT
prod
parseurl1.3.33.86 kBMIT
prod
uid-safe2.0.02.87 kBMIT
prod
1
utils-merge1.0.01.65 kBMIT
prod

Visualizations

Frequently Asked Questions

What does express-session do?

Express-Session is a simple session middleware for Express. Express-Session creates a session middleware with the given options. It's important to note that the session data is not saved in the cookie itself, just the session ID. Session data is stored server-side. Its default server-side session storage, MemoryStore, is not designed for a production environment as it will leak memory under most conditions, does not scale past a single process, and is primarily designed for debugging and developing.

How do you use express-session?

To use Express-Session in your JavaScript application, you should first install it from the npm registry using the command: npm install express-session. After the installation is complete, you can require it in your application like so:

var session = require('express-session')

app.use(session({
  secret: 'keyboard cat',
  resave: false,
  saveUninitialized: true,
  cookie: { secure: true }
}))

In the example above, the express-session middleware is used with secret as 'keyboard cat', and resave and saveUninitialized options set as false and true respectively. The cookie option is set with the secure property as true.

If you are using Express in conjunction with a reverse proxy and the "trust proxy" setting is set to 1, you can use this sample code:

var app = express()
app.set('trust proxy', 1) // trust first proxy
app.use(session({
  secret: 'keyboard cat',
  resave: false,
  saveUninitialized: true,
  cookie: { secure: true }
}))

Where are the express-session docs?

The Express-session documentation is available directly in the npm package repository. You can find everything you need to know about Express-Session, including installation, API details, options, request properties, compatible session stores, and more in the Express-session's npm documentation at https://www.npmjs.com/package/express-session. Also, the repository for the Express-session project is on Github at git+https://github.com/expressjs/session.git.