CVE-2021-21365: Bk2k/bootstrap package Cross-Site Scripting Vulnerability

MODERATE
Advisory Identifier: GHSA-p48w-vf3c-rqjx
CVSS 5.4
CWE-79
Published
Advisory Summary

CVE-2021-21365 is a MODERATE (CVSS 5.4) cross-site scripting vulnerability (CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')) affecting Bk2k/bootstrap package libraries in the Packagist ecosystem. The issue involves cross-site scripting in bootstrap package. Remediation is available by upgrading affected packages to version 7.1.2, 8.0.8, 9.0.4, 9.1.3, 10.0.10, 11.0.3.

CVE-2021-21365 at a Glance

CVE Identifier CVE-2021-21365
GHSA Identifier GHSA-p48w-vf3c-rqjx
Severity MODERATE
CVSS v3.1 Base Score 5.4
CWE Classification CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
Affected Product Bk2k/bootstrap package
Package Ecosystem Packagist
Published Date
Last Updated

Security Impact

CVSS: 5.4

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required Low (PR:L)
User Interaction Required (UI:R)
Scope Changed (S:C)
Confidentiality Low (C:L)
Integrity Low (I:L)
Availability None (A:N)

How to Fix CVE-2021-21365

To remediate this vulnerability, upgrade all affected Bk2k/bootstrap package dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

bk2k/bootstrap-package fixed: 7.1.2
Upgrade bk2k/bootstrap-package to 7.1.2
bk2k/bootstrap-package fixed: 8.0.8
Upgrade bk2k/bootstrap-package to 8.0.8
bk2k/bootstrap-package fixed: 9.0.4
Upgrade bk2k/bootstrap-package to 9.0.4
bk2k/bootstrap-package fixed: 9.1.3
Upgrade bk2k/bootstrap-package to 9.1.3
bk2k/bootstrap-package fixed: 10.0.10
Upgrade bk2k/bootstrap-package to 10.0.10
bk2k/bootstrap-package fixed: 11.0.3
Upgrade bk2k/bootstrap-package to 11.0.3
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for bk2k/bootstrap-package

How to Check if You Are Affected

To determine whether your application is affected by CVE-2021-21365, inspect your project dependencies for Bk2k/bootstrap package:

inspect dependencies for bk2k/bootstrap-package

Analyze the terminal output to locate any version of Bk2k/bootstrap package in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 7.1.2), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting'), where the product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. In Bk2k/bootstrap package, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Problem It has been discovered that rendering content in the website frontend is vulnerable to cross-site scripting. A valid backend user account is needed to exploit this vulnerability. The following templates are affected by the vulnerability: * `Resources/Private/Partials/ContentElements/Carousel/Item/CallToAction.html` * `Resources/Private/Partials/ContentElements/Carousel/Item/Header.html` * `Resources/Private/Partials/ContentElements/Carousel/Item/Text.html` * `Resources/Private/Partials/ContentElements/Carousel/Item/TextAndImage.html` * `Resources/Private/Partials/ContentElements/Header/SubHeader.html` Users of the extension, who have overwritten the affected templates with custom code must manually apply the security fix as shown in [this Git commit](https://github.com/benjaminkott/bootstrap_package/commit/de3a568fc311d6712d9339643e51e8627c80530b). ### Solution Update to version 7.1.2, 8.0.8, 9.0.4, 9.1.3, 10.0.10 or 11.0.3 of the Bootstrap Package that fix the problem described. Updated version are available from the TYPO3 extension manager, Packagist and at https://extensions.typo3.org/extension/download/bootstrap_package/. ### Credits Thanks to TYPO3 security team member Oliver Hader who reported and fixed the issue.

CVE-2021-21365 Affected Bk2k/bootstrap package Versions

6 component(s)
Fixed Versions:
7.1.28.0.89.0.49.1.310.0.1011.0.3
Product / Package Ecosystem Affected Versions Fixed Version
bk2k/bootstrap-package
Packagist
≥ 7.1.0
< 7.1.2
7.1.2
bk2k/bootstrap-package
Packagist
≥ 8.0.0
< 8.0.8
8.0.8
bk2k/bootstrap-package
Packagist
≥ 9.0.0
< 9.0.4
9.0.4
bk2k/bootstrap-package
Packagist
≥ 9.1.0
< 9.1.3
9.1.3
bk2k/bootstrap-package
Packagist
≥ 10.0.0
< 10.0.10
10.0.10
bk2k/bootstrap-package
Packagist
≥ 11.0.0
< 11.0.3
11.0.3

References

Frequently Asked Questions

What is CVE-2021-21365?
CVE-2021-21365 is a security vulnerability in Bk2k/bootstrap package involving Cross-Site Scripting in Bootstrap Package under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting').
Which Bk2k/bootstrap package versions are affected?
Affected versions include releases prior to 7.1.2, 8.0.8, 9.0.4, 9.1.3, 10.0.10, 11.0.3 across affected packages: bk2k/bootstrap-package.
What version fixes CVE-2021-21365?
Upgrading to 7.1.2, 8.0.8, 9.0.4, 9.1.3, 10.0.10, 11.0.3 (or the latest patched release for your respective branch) resolves the vulnerability.
Is bk2k/bootstrap-package affected?
Yes, bk2k/bootstrap-package is affected in releases prior to 7.1.2, 8.0.8, 9.0.4, 9.1.3, 10.0.10, 11.0.3. Upgrade your dependency to 7.1.2, 8.0.8, 9.0.4, 9.1.3, 10.0.10, 11.0.3 or later.
What is the CVSS score of CVE-2021-21365?
CVE-2021-21365 has a CVSS v3.1 base score of 5.4 (MODERATE) with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N.
What CWE is associated with CVE-2021-21365?
CVE-2021-21365 is classified under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') (The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.).
How can I check Packagist dependencies for CVE-2021-21365?
Run the dependency tree command: 'inspect dependencies for bk2k/bootstrap-package'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-p48w-vf3c-rqjx",
  "modified" : "2021-04-27T19:43:14Z",
  "published" : "2021-04-29T21:51:21Z",
  "aliases" : [ "CVE-2021-21365" ],
  "summary" : "Cross-Site Scripting in Bootstrap Package",
  "details" : "### Problem\nIt has been discovered that rendering content in the website frontend is vulnerable to cross-site scripting. A valid backend user account is needed to exploit this vulnerability.\n\nThe following templates are affected by the vulnerability:\n\n* `Resources/Private/Partials/ContentElements/Carousel/Item/CallToAction.html`\n* `Resources/Private/Partials/ContentElements/Carousel/Item/Header.html`\n* `Resources/Private/Partials/ContentElements/Carousel/Item/Text.html`\n* `Resources/Private/Partials/ContentElements/Carousel/Item/TextAndImage.html`\n* `Resources/Private/Partials/ContentElements/Header/SubHeader.html`\n\nUsers of the extension, who have overwritten  the affected templates with custom code must manually apply the security fix as shown in [this Git commit](https://github.com/benjaminkott/bootstrap_package/commit/de3a568fc311d6712d9339643e51e8627c80530b).\n\n### Solution\nUpdate to version 7.1.2, 8.0.8, 9.0.4, 9.1.3, 10.0.10 or 11.0.3 of the Bootstrap Package that fix the problem described.\n\nUpdated version are available from the TYPO3 extension manager, Packagist and at https://extensions.typo3.org/extension/download/bootstrap_package/.\n\n### Credits\nThanks to TYPO3 security team member Oliver Hader who reported and fixed the issue.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "bk2k/bootstrap-package"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "7.1.0"
      }, {
        "fixed" : "7.1.2"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "bk2k/bootstrap-package"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "8.0.0"
      }, {
        "fixed" : "8.0.8"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "bk2k/bootstrap-package"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "9.0.0"
      }, {
        "fixed" : "9.0.4"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "bk2k/bootstrap-package"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "9.1.0"
      }, {
        "fixed" : "9.1.3"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "bk2k/bootstrap-package"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "10.0.0"
      }, {
        "fixed" : "10.0.10"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "bk2k/bootstrap-package"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "11.0.0"
      }, {
        "fixed" : "11.0.3"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/benjaminkott/bootstrap_package/security/advisories/GHSA-p48w-vf3c-rqjx"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2021-21365"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/benjaminkott/bootstrap_package/commit/de3a568fc311d6712d9339643e51e8627c80530b"
  }, {
    "type" : "WEB",
    "url" : "https://typo3.org/security/advisory/typo3-ext-sa-2021-007"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-79" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2021-04-27T19:43:14Z",
    "nvd_published_at" : "2021-04-27T20:15:00Z"
  }
}