{
  "affected": [
    {
      "ranges": [
        {
          "database_specific": {
            "source": "REFERENCES"
          },
          "events": [
            {
              "introduced": "0"
            },
            {
              "fixed": "f80c215a283cd045d2a371403e6eba88b2911192"
            }
          ],
          "repo": "https://github.com/discourse/discotoc",
          "type": "GIT"
        }
      ]
    }
  ],
  "aliases": [
    "GHSA-m44p-w923-w32h"
  ],
  "database_specific": {
    "cna_assigner": "GitHub_M",
    "cwe_ids": [
      "CWE-79"
    ],
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/39xxx/CVE-2022-39270.json",
    "unresolved_ranges": [
      {
        "extracted_events": [
          {
            "fixed": "2.1.0"
          }
        ],
        "source": "AFFECTED_FIELD"
      }
    ]
  },
  "details": "DiscoTOC is a Discourse theme component that generates a table of contents for topics. Users that can create topics in TOC-enabled categories (and have sufficient trust level - configured in component's settings) are able to inject arbitrary HTML on that topic's page. The issue has been fixed on the `main` branch. Admins can update the theme component through the admin UI (Customize -\u003e Themes -\u003e Components -\u003e DiscoTOC -\u003e Check for Updates). Alternatively, admins can temporarily disable the DiscoTOC theme component.",
  "id": "CVE-2022-39270",
  "modified": "2026-07-15T01:48:56.623502526Z",
  "published": "2022-10-06T00:00:00Z",
  "references": [
    {
      "type": "ADVISORY",
      "url": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/39xxx/CVE-2022-39270.json"
    },
    {
      "type": "ADVISORY",
      "url": "https://github.com/discourse/DiscoTOC/security/advisories/GHSA-m44p-w923-w32h"
    },
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2022-39270"
    },
    {
      "type": "FIX",
      "url": "https://github.com/discourse/DiscoTOC/commit/f80c215a283cd045d2a371403e6eba88b2911192"
    }
  ],
  "schema_version": "1.8.0",
  "severity": [
    {
      "score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N",
      "type": "CVSS_V3"
    }
  ],
  "summary": "Arbitrary HTML injection in table-of-contents theme component in DiscoTOC"
}