Socket
Socket
Sign inDemoInstall

helmet

Package Overview
Dependencies
Maintainers
2
Versions
130
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

helmet - npm Package Versions

1
13

4.4.1

Diff

Changelog

Source

4.4.1 - 2021-01-18

Changed

  • Shrink the published package by about 2.5 kB
evanhahn
published 4.4.0 •

Changelog

Source

4.4.0 - 2021-01-17

Added

  • helmet.originAgentCluster: a new middleware for the Origin-Agent-Cluster header, disabled by default
evanhahn
published 4.3.1 •

Changelog

Source

4.3.1 - 2020-12-27

Fixed

  • helmet.contentSecurityPolicy: broken TypeScript types. See #283
evanhahn
published 4.3.0 •

Changelog

Source

4.3.0 - 2020-12-27

Added

  • helmet.contentSecurityPolicy: setting the default-src to helmet.contentSecurityPolicy.dangerouslyDisableDefaultSrc disables it

Changed

  • helmet.frameguard: slightly improved error messages for non-strings
evanhahn
published 4.2.0 •

Changelog

Source

4.2.0 - 2020-11-01

Added

  • helmet.contentSecurityPolicy: get the default directives with contentSecurityPolicy.getDefaultDirectives()

Changed

  • helmet() now supports objects that don't have Object.prototype in their chain, such as Object.create(null), as options
  • helmet.expectCt: max-age is now first. See #264
evanhahn
published 4.1.1 •

Changelog

Source

4.1.1 - 2020-09-10

Changed

  • Fixed a few errors in the README
evanhahn
published 4.1.0 •

Changelog

Source

4.1.0 - 2020-08-15

Added

  • helmet.contentSecurityPolicy:
    • Directive values can now include functions, as they could in Helmet 3. See #243

Changed

  • Helmet should now play more nicely with TypeScript

Removed

  • The HelmetOptions interface is no longer exported. This only affects TypeScript users. If you need the functionality back, see this comment
evanhahn
published 4.1.0-rc.2 •

evanhahn
published 4.1.0-rc.1 •

evanhahn
published 4.0.0 •

Changelog

Source

4.0.0 - 2020-08-02

See the Helmet 4 upgrade guide for help upgrading from Helmet 3.

Added

  • helmet.contentSecurityPolicy:
    • If no default-src directive is supplied, an error is thrown
    • Directive lists can be any iterable, not just arrays

Changed

  • This package no longer has dependencies. This should have no effect on end users, other than speeding up installation time.
  • helmet.contentSecurityPolicy:
    • There is now a default set of directives if none are supplied
    • Duplicate keys now throw an error. See helmetjs/csp#73
    • This middleware is more lenient, allowing more directive names or values
  • helmet.xssFilter now disables the buggy XSS filter by default. See #230

Removed

  • Dropped support for old Node versions. Node 10+ is now required
  • helmet.featurePolicy. If you still need it, use the feature-policy package on npm.
  • helmet.hpkp. If you still need it, use the hpkp package on npm.
  • helmet.noCache. If you still need it, use the nocache package on npm.
  • helmet.contentSecurityPolicy:
    • Removed browser sniffing (including the browserSniff and disableAndroid parameters). See helmetjs/csp#97
    • Removed conditional support. This includes directive functions and support for a function as the reportOnly. Read this if you need help.
    • Removed a lot of checks—you should be checking your CSP with a different tool
    • Removed support for legacy headers (and therefore the setAllHeaders parameter). Read this if you need help.
    • Removed the loose option
    • Removed support for functions as directive values. You must supply an iterable of strings
  • helmet.frameguard:
  • helmet.hidePoweredBy no longer accepts arguments. See this article to see how to replicate the removed behavior. See #224.
  • helmet.hsts:
  • helmet.xssFilter no longer accepts options. Read "How to disable blocking with X-XSS-Protection" and "How to enable the report directive with X-XSS-Protection" if you need the legacy behavior.
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc