Skip to content
Heist/ feed
Back to feed
Critical

justhtml before 1.16.0 Multiple Security Issues via Sanitization

Type: advisorySources: OSV

justhtml before 1.16.0 contains multiple HTML sanitization bypass issues that can allow active/dangerous content (e.g., script or style) to survive sanitization, potentially leading to cross-site scripting. The issues primarily affect advanced usage rather than the default JustHTML(..., sanitize=True) path for ordinary parsed HTML: mutating or reusing sanitization policy objects (including exported defaults) could weaken later sanitization; programmatic DOM input to sanitize()/sanitize_dom() could miss mixed-case tag names (e.g., ScRiPt, StYlE); crafted programmatic doctype names could serialize into active markup; and custom policies preserving SVG or MathML could allow animation elements, presentation attributes with external url(...) references, or DOM trees mislabeled as namespace="html" to bypass foreign-content checks. Fixed in 1.16.0.

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2026-7808
Confirmed fixed CVEs
Not specified
Updated in this feed
7 Nov 2026, 01:36 UTC · Revision 1

Source evidence

justhtml before 1.16.0 Multiple Security Issues via Sanitization

core-osv · Original source

Published 23 Aug 2026, 13:34 UTC

justhtml before 1.16.0 contains multiple HTML sanitization bypass issues that can allow active/dangerous content (e.g., script or style) to survive sanitization, potentially leading to cross-site scripting. The issues primarily affect advanced usage rather than the default JustHTML(..., sanitize=True) path for ordinary parsed HTML: mutating or reusing sanitization policy objects (including exported defaults) could weaken later sanitization; programmatic DOM input to sanitize()/sanitize_dom() could miss mixed-case tag names (e.g., ScRiPt, StYlE); crafted programmatic doctype names could serialize into active markup; and custom policies preserving SVG or MathML could allow animation elements, presentation attributes with external url(...) references, or DOM trees mislabeled as namespace="html" to bypass foreign-content checks. Fixed in 1.16.0.

osv:CVE-2026-7808
Complete source record
{
  "id": "7ab0a0a68a47489d45bf3618d038f3c8d55146497f92bcd34b52904f6a8819d2",
  "url": "https://osv.dev/vulnerability/CVE-2026-7808",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "justhtml before 1.16.0 Multiple Security Issues via Sanitization",
    "summary": "justhtml before 1.16.0 contains multiple HTML sanitization bypass issues that can allow active/dangerous content (e.g., script or style) to survive sanitization, potentially leading to cross-site scripting. The issues primarily affect advanced usage rather than the default JustHTML(..., sanitize=True) path for ordinary parsed HTML: mutating or reusing sanitization policy objects (including exported defaults) could weaken later sanitization; programmatic DOM input to sanitize()/sanitize_dom() could miss mixed-case tag names (e.g., ScRiPt, StYlE); crafted programmatic doctype names could serialize into active markup; and custom policies preserving SVG or MathML could allow animation elements, presentation attributes with external url(...) references, or DOM trees mislabeled as namespace=\"html\" to bypass foreign-content checks. Fixed in 1.16.0.",
    "evidence": "osv:CVE-2026-7808",
    "products": [],
    "severity": "critical",
    "structured": {
      "id": "CVE-2026-7808",
      "aliases": [
        "CVE-2026-7808",
        "GHSA-4p64-v8f5-r2gx"
      ],
      "metrics": [
        {
          "type": "CVSS_V4",
          "score": "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/emilstenstrom/justhtml",
              "type": "GIT",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "273422f9f8a1b87cb1c13d892b50d3e42141d4e8"
                }
              ],
              "database_specific": {
                "extracted_events": [
                  {
                    "range": [
                      {
                        "introduced": "0"
                      },
                      {
                        "fixed": "1.16.0"
                      }
                    ],
                    "source": "AFFECTED_FIELD",
                    "strategy": "StandardRange"
                  },
                  {
                    "range": [
                      {
                        "introduced": "0"
                      },
                      {
                        "fixed": "1.16.0"
                      }
                    ],
                    "source": "DESCRIPTION"
                  }
                ]
              }
            }
          ],
          "versions": [
            "v1.15.0",
            "v1.14.0",
            "v1.13.0",
            "v1.12.0",
            "v1.11.0",
            "v1.10.0",
            "v1.9.1",
            "v1.9.0",
            "v1.8.0",
            "v1.7.0",
            "v1.6.0",
            "v1.5.0",
            "v1.4.0",
            "v1.3.0",
            "v1.2.0",
            "v1.1.0",
            "v1.0.0",
            "v0.40.0",
            "v0.39.0",
            "v0.38.0",
            "v0.37.0",
            "v0.36.0",
            "v0.35.0",
            "v0.34.0",
            "v0.33.0",
            "v0.32.0",
            "v0.31.0",
            "v0.30.0",
            "v0.29.0",
            "v0.28.0",
            "v0.27.0",
            "v0.26.0",
            "v0.25.0",
            "v0.24.0",
            "v0.23.0",
            "v0.22.0",
            "v0.21.0",
            "v0.20.0",
            "v0.19.0",
            "v0.18.0",
            "v0.17.0",
            "v0.16.0",
            "v0.15.0",
            "v0.14.0",
            "v0.13.1",
            "v0.13.0",
            "v0.12.0",
            "v0.11.0",
            "v0.10.0",
            "v0.9.0",
            "v0.8.0",
            "v0.7.0",
            "v0.6.0",
            "v0.5.2",
            "v0.5.1",
            "v0.5.0",
            "v0.4.0",
            "v0.3.0",
            "v0.2.0",
            "v0.1.0"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-7808.json"
          }
        }
      ],
      "modified": "2026-10-28T02:30:48.704458016Z",
      "provider": "osv",
      "references": [
        "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/7xxx/CVE-2026-7808.json",
        "https://github.com/EmilStenstrom/justhtml/security/advisories/GHSA-4p64-v8f5-r2gx",
        "https://nvd.nist.gov/vuln/detail/CVE-2026-7808",
        "https://www.vulncheck.com/advisories/justhtml-before-multiple-security-issues-via-sanitization"
      ],
      "provider_metadata": {
        "cwe_ids": [
          "CWE-20"
        ],
        "cna_assigner": "VulnCheck",
        "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/7xxx/CVE-2026-7808.json"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2026-7808",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 517034,
  "published_at": "2026-08-23T13:34:13.232+00:00"
}