Is bootstrap 4.2 vulnerable?

npm · 1 release from 4.2.1 to 4.2.1 · latest bootstrap is 5.3.8 · checked 1 Nov 2026

Yes: 1 known advisory

Yes. bootstrap 4.2.1, the last 4.2 release, is affected by 1 known security advisory (1 medium), including CVE-2019-8331. Upgrade to 4.3.1 or later to fix all of them.

Upgrade with:npm install bootstrap@4.3.1

Is your project affected?

Private repo? Upload its lockfile instead, or connect GitHub to check every repo.

Advisories affecting bootstrap 4.2.1

  • MediumCVE-2019-8331GHSA-9v3m-8fp8-mj9922 Feb 2019

    Bootstrap Vulnerable to Cross-Site Scripting

    Affected
    >=4.0.0 <4.3.1 · >=3.0.0 <3.4.1
    Fixed in
    3.4.1, 4.3.1

Which of your client projects are still on bootstrap 4.2?

NPMscan reads the lockfiles in every GitHub repo you pick, finds the exact bootstrap version each one installs, and checks it against these advisories. Each finding comes with the command that fixes it.

Other bootstrap versions

Advisory data from OSV.dev (opens OSV.dev in a new tab), which includes the GitHub Advisory Database. Release list from the npm registry. Refreshed daily.