Skip to content
Heist/ feed
Back to feed
Unrated

Security advisory

Type: advisorySources: OSVCVE: CVE-2022-21158

A stored cross-site scripting vulnerability in marktext versions prior to v0.17.0 due to improper handling of the link (with javascript: scheme) inside the document may allow an attacker to execute an arbitrary script on the PC of the user using marktext.

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2022-21158
Confirmed fixed CVEs
Not specified
Updated in this feed
3 Nov 2026, 15:56 UTC · Revision 1

Source evidence

CVE-2022-21158

core-osv · Original source

Published 7 Mar 2022, 09:00 UTC

A stored cross-site scripting vulnerability in marktext versions prior to v0.17.0 due to improper handling of the link (with javascript: scheme) inside the document may allow an attacker to execute an arbitrary script on the PC of the user using marktext.

osv:CVE-2022-21158
Complete source record
{
  "id": "c2ddddb036ee4258aef8228f560bae476f53a0c829a23714165b51af54862b90",
  "url": "https://osv.dev/vulnerability/CVE-2022-21158",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "CVE-2022-21158",
    "summary": "A stored cross-site scripting vulnerability in marktext versions prior to v0.17.0 due to improper handling of the link (with javascript: scheme) inside the document may allow an attacker to execute an arbitrary script on the PC of the user using marktext.",
    "evidence": "osv:CVE-2022-21158",
    "products": [],
    "severity": "unknown",
    "structured": {
      "id": "CVE-2022-21158",
      "aliases": [
        "CVE-2022-21158"
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/marktext/marktext",
              "type": "GIT",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "637395a1f78278e375e0753c7b18e7833a6b9d58"
                }
              ],
              "database_specific": {
                "extracted_events": [
                  {
                    "range": [
                      {
                        "introduced": "0"
                      },
                      {
                        "fixed": "0.17.0"
                      }
                    ],
                    "source": "AFFECTED_FIELD",
                    "strategy": "VersionTextExtraction"
                  },
                  {
                    "range": [
                      {
                        "fixed": "637395a1f78278e375e0753c7b18e7833a6b9d58"
                      }
                    ],
                    "source": "REFERENCES_TAG",
                    "original_tag": "v0.17.0"
                  },
                  {
                    "cpe": "cpe:2.3:a:marktext:marktext:*:*:*:*:*:*:*:*",
                    "range": [
                      {
                        "introduced": "0"
                      },
                      {
                        "fixed": "0.17.0"
                      }
                    ],
                    "source": "CPE_RANGE"
                  }
                ]
              }
            }
          ],
          "versions": [
            "v0.16.3",
            "v0.16.2",
            "v0.16.0",
            "v0.16.0-rc.3",
            "v0.16.0-rc.2",
            "v0.16.0-rc.1",
            "v0.15.0",
            "v0.15.0-rc.3",
            "v0.15.0-rc.2",
            "v0.15.0-rc.1",
            "v0.14.0",
            "v0.14.0-rc.1",
            "v0.13.65",
            "v0.13.53",
            "v0.13.50",
            "v0.12.25",
            "v0.12.20",
            "v0.11.42",
            "v0.10.21",
            "v0.9.25",
            "v0.8.12",
            "v0.7.17",
            "v0.6.13",
            "v0.5.2",
            "v0.4.0",
            "v0.3.0",
            "v0.0.1"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2022-21158.json"
          }
        }
      ],
      "modified": "2026-10-28T02:30:30.130033702Z",
      "provider": "osv",
      "references": [
        "https://github.com/marktext/marktext/releases/tag/v0.17.0",
        "https://jvn.jp/en/jp/JVN89524240/index.html",
        "https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/21xxx/CVE-2022-21158.json",
        "https://nvd.nist.gov/vuln/detail/CVE-2022-21158"
      ],
      "provider_metadata": {
        "cna_assigner": "jpcert",
        "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/21xxx/CVE-2022-21158.json"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2022-21158",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": null
  },
  "source_id": "core-osv",
  "document_id": 497063,
  "published_at": "2022-03-07T09:00:35+00:00"
}