CVE-2016-3956: Infoleak

Published Jul 2, 2016
·
Updated

Affected versions of the npm package include the bearer token of the logged in user in every request made by the CLI, even if the request is not directed towards the user's active registry.

An attacker could create an HTTP server to collect tokens, and by various means including but not limited to install scripts, cause the npm CLI to make a request to that server, which would compromise the user's token.

This compromised token could be used to do anything that the user could do, including publishing new packages.

Recommendation

1. Update npm with npm install npm@latest -g 2. Revoke your Tokens 3. Enable Two-Factor Authentication

Other sources

The CLI in npm before 2.15.1 and 3.x before 3.8.3, as used in Node.js 0.10 before 0.10.44, 0.12 before 0.12.13, 4 before 4.4.2, and 5 before 5.10.0, includes bearer tokens with arbitrary requests, which allows remote HTTP servers to obtain sensitive information by reading Authorization headers.

— MITRE

Affected Software

98 affected componentsFixes available
IBM Sdk Nodejs<=1.1.0.20
IBM Sdk Nodejs<=1.2.0.10
IBM Sdk Nodejs<=4.4.1.0
Nodejs Node.js=0.10.0
Nodejs Node.js=0.10.1
Nodejs Node.js=0.10.2
Nodejs Node.js=0.10.3
Nodejs Node.js=0.10.4
Nodejs Node.js=0.10.5
Nodejs Node.js=0.10.6
Nodejs Node.js=0.10.7
Nodejs Node.js=0.10.8
Nodejs Node.js=0.10.9
Nodejs Node.js=0.10.10
Nodejs Node.js=0.10.11
Nodejs Node.js=0.10.12
Nodejs Node.js=0.10.13
Nodejs Node.js=0.10.14
Nodejs Node.js=0.10.15
Nodejs Node.js=0.10.16
Nodejs Node.js=0.10.16-isaacs-manual
Nodejs Node.js=0.10.17
Nodejs Node.js=0.10.18
Nodejs Node.js=0.10.19
Nodejs Node.js=0.10.20
Nodejs Node.js=0.10.21
Nodejs Node.js=0.10.22
Nodejs Node.js=0.10.23
Nodejs Node.js=0.10.24
Nodejs Node.js=0.10.25
Nodejs Node.js=0.10.26
Nodejs Node.js=0.10.27
Nodejs Node.js=0.10.28
Nodejs Node.js=0.10.29
Nodejs Node.js=0.10.30
Nodejs Node.js=0.10.31
Nodejs Node.js=0.10.32
Nodejs Node.js=0.10.33
Nodejs Node.js=0.10.34
Nodejs Node.js=0.10.35
Nodejs Node.js=0.10.36
Nodejs Node.js=0.10.37
Nodejs Node.js=0.10.38
Nodejs Node.js=0.10.39
Nodejs Node.js=0.10.40
Nodejs Node.js=0.10.41
Nodejs Node.js=0.12.0
Nodejs Node.js=0.12.1
Nodejs Node.js=0.12.2
Nodejs Node.js=0.12.3
Nodejs Node.js=0.12.4
Nodejs Node.js=0.12.5
Nodejs Node.js=0.12.6
Nodejs Node.js=0.12.7
Nodejs Node.js=0.12.8
Nodejs Node.js=0.12.9
Nodejs Node.js=4.0.0
Nodejs Node.js=4.1.0
Nodejs Node.js=4.1.1
Nodejs Node.js=4.1.2
Nodejs Node.js=4.2.0
Nodejs Node.js=4.2.1
Nodejs Node.js=4.2.2
Nodejs Node.js=4.2.3
Nodejs Node.js=4.2.4
Nodejs Node.js=4.2.5
Nodejs Node.js=4.2.6
Nodejs Node.js=4.3.0
Nodejs Node.js=4.3.1
Nodejs Node.js=4.3.1-rc.1
Nodejs Node.js=4.3.1-rc.2
Nodejs Node.js=4.3.2
Nodejs Node.js=4.4.0
Nodejs Node.js=4.4.0-rc.1
Nodejs Node.js=4.4.0-rc.2
Nodejs Node.js=4.4.0-rc.3
Nodejs Node.js=4.4.0-rc.4
Nodejs Node.js=4.4.1
Nodejs Node.js=5.0.0
Nodejs Node.js=5.1.0
Nodejs Node.js=5.1.1
Nodejs Node.js=5.2.0
Nodejs Node.js=5.3.0
Nodejs Node.js=5.4.0
Nodejs Node.js=5.4.1
Nodejs Node.js=5.5.0
Nodejs Node.js=5.6.0
Nodejs Node.js=5.7.0
Nodejs Node.js=5.7.1
Nodejs Node.js=5.8.0
Nodejs Node.js=5.8.1-rc.1
Nodejs Node.js=5.9.0
Nodejs Node.js=5.9.1
npmjs npm<2.15.1
npmjs npm>=3.0.0<3.8.3
npm/npm>=3.0.0<=3.8.2
3.8.3
npm/npm<=2.15.0
2.15.1
debian/npm
5.8.0+ds-2

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade npm/npm to a version that resolves this vulnerability.

    Fixed in 3.8.3
  2. Upgrade

    Upgrade npm/npm to a version that resolves this vulnerability.

    Fixed in 2.15.1
  3. Upgrade

    Upgrade debian/npm to a version that resolves this vulnerability.

    Fixed in 5.8.0+ds-2
  4. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 2.15.1
  5. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 3.8.3
  6. Configuration

    Enable Two-Factor Authentication for the npm account.

    npm account Two-Factor Authentication = enabled
  7. Operational

    Revoke npm tokens that may have been exposed.

Event History

Jul 2, 2016
CVE Published
via MITRE·02:00 PM
Data Sourced
via MITRE·02:00 PM
Description
Data Sourced
02:59 PM
RemedyDescriptionSeverityWeaknessAffected Software
Jul 31, 2018
Advisory Published
via GitHub·10:58 PM
Data Sourced
via GitHub·10:58 PM
DescriptionWeaknessAffected Software

Frequently Asked Questions

1

What is the severity of CVE-2016-3956?

The severity of CVE-2016-3956 is classified as moderate, as it allows remote servers to potentially access sensitive information through the Authorization header.

2

How do I fix CVE-2016-3956?

To fix CVE-2016-3956, update npm to versions 2.15.1 or later, or 3.8.3 or later.

3

Which versions of Node.js are affected by CVE-2016-3956?

CVE-2016-3956 affects Node.js versions 0.10 before 0.10.44, 0.12 before 0.12.13, 4 before 4.4.2, and 5 before 5.10.0.

4

Does CVE-2016-3956 affect npm?

Yes, CVE-2016-3956 affects npm versions prior to 2.15.1 and versions between 3.0.0 and 3.8.2.

5

What is the impact of CVE-2016-3956?

The impact of CVE-2016-3956 is that it allows unauthorized access to bearer tokens in HTTP requests, posing a risk of sensitive data exposure.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203