Skip to content
Heist/ feed
Back to feed
Medium

plone.app.textfield: Stored XSS by spoofing mime type

Type: advisorySources: OSV

plone.app.textfield provides a zope.schema-style field type called RichText for storing a value with a related MIME type. Prior to 2.0.2, 3.0.2, and 4.0.1, depending on the release line, RichTextValue.output returns an unsanitized stored RichText value when mimeType equals outputMimeType, including values that claim the text/x-html-safe output type. This equality shortcut bypasses the safe_html transform even though the transform itself correctly removes event-handler attributes and unsafe URI schemes. Equal types can result from a RichText field configured with the same mimeType and outputMimeType or from REST API input that supplies text/x-html-safe as its content type. The raw stored value is then emitted through tal:content=structure without escaping, allowing a user who can set a RichText field to store JavaScript that executes in a viewer's browser. This issue is fixed in versions 2.0.2, 3.0.2, and 4.0.1.

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

Source evidence

plone.app.textfield: Stored XSS by spoofing mime type

core-osv · Original source

Published 15 Sept 2026, 16:38 UTC

plone.app.textfield provides a zope.schema-style field type called RichText for storing a value with a related MIME type. Prior to 2.0.2, 3.0.2, and 4.0.1, depending on the release line, RichTextValue.output returns an unsanitized stored RichText value when mimeType equals outputMimeType, including values that claim the text/x-html-safe output type. This equality shortcut bypasses the safe_html transform even though the transform itself correctly removes event-handler attributes and unsafe URI schemes. Equal types can result from a RichText field configured with the same mimeType and outputMimeType or from REST API input that supplies text/x-html-safe as its content type. The raw stored value is then emitted through tal:content=structure without escaping, allowing a user who can set a RichText field to store JavaScript that executes in a viewer's browser. This issue is fixed in versions 2.0.2, 3.0.2, and 4.0.1.

osv:CVE-2026-54503
Complete source record
{
  "id": "73834cabd963c7c909db8aea86c7d8cb19b2dead814d923ad8243f539a0a47aa",
  "url": "https://osv.dev/vulnerability/CVE-2026-54503",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "plone.app.textfield: Stored XSS by spoofing mime type",
    "summary": "plone.app.textfield provides a zope.schema-style field type called RichText for storing a value with a related MIME type. Prior to 2.0.2, 3.0.2, and 4.0.1, depending on the release line, RichTextValue.output returns an unsanitized stored RichText value when mimeType equals outputMimeType, including values that claim the text/x-html-safe output type. This equality shortcut bypasses the safe_html transform even though the transform itself correctly removes event-handler attributes and unsafe URI schemes. Equal types can result from a RichText field configured with the same mimeType and outputMimeType or from REST API input that supplies text/x-html-safe as its content type. The raw stored value is then emitted through tal:content=structure without escaping, allowing a user who can set a RichText field to store JavaScript that executes in a viewer's browser. This issue is fixed in versions 2.0.2, 3.0.2, and 4.0.1.",
    "evidence": "osv:CVE-2026-54503",
    "products": [],
    "severity": "medium",
    "structured": {
      "id": "CVE-2026-54503",
      "aliases": [
        "CVE-2026-54503",
        "GHSA-4r4f-gg25-rmg5",
        "PYSEC-2026-3497"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/plone/plone.app.textfield",
              "type": "GIT",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "c08d333f818afaaf34031de3925c6fab6cbaafb1"
                },
                {
                  "introduced": "3f32e6b0376e9c0155205ecb9a28550c3b9204e1"
                },
                {
                  "fixed": "0da2e11a5452366f172e95e8a1579bba2a4e2b53"
                },
                {
                  "introduced": "cf07102d2d99ba14b706224888d0341f558d0c2e"
                },
                {
                  "fixed": "6f00dda28350463a90f1d3bf362810a59bcc3ade"
                },
                {
                  "fixed": "0da1aeec2406cf640977eb857a03e792d2c7cac2"
                },
                {
                  "fixed": "467638e500d804c637031387a227a2b02d12a86f"
                },
                {
                  "fixed": "781d517a38524087fe57525a94806684908f852f"
                }
              ],
              "database_specific": {
                "extracted_events": [
                  {
                    "range": [
                      {
                        "introduced": "0"
                      },
                      {
                        "fixed": "2.0.2"
                      }
                    ],
                    "source": "AFFECTED_FIELD",
                    "strategy": "StringRangeExpression"
                  },
                  {
                    "range": [
                      {
                        "introduced": "3.0.0"
                      },
                      {
                        "fixed": "3.0.2"
                      }
                    ],
                    "source": "AFFECTED_FIELD",
                    "strategy": "StringRangeExpression"
                  },
                  {
                    "range": [
                      {
                        "introduced": "4.0.0"
                      },
                      {
                        "fixed": "4.0.1"
                      }
                    ],
                    "source": "AFFECTED_FIELD",
                    "strategy": "StringRangeExpression"
                  },
                  {
                    "range": [
                      {
                        "fixed": "0da1aeec2406cf640977eb857a03e792d2c7cac2"
                      }
                    ],
                    "source": "REFERENCES_COMMIT"
                  },
                  {
                    "range": [
                      {
                        "fixed": "467638e500d804c637031387a227a2b02d12a86f"
                      }
                    ],
                    "source": "REFERENCES_COMMIT"
                  },
                  {
                    "range": [
                      {
                        "fixed": "781d517a38524087fe57525a94806684908f852f"
                      }
                    ],
                    "source": "REFERENCES_COMMIT"
                  }
                ]
              }
            }
          ],
          "versions": [
            "4.0.0",
            "3.0.1",
            "3.0.0",
            "2.0.1",
            "2.0.0",
            "1.3.7",
            "1.3.6",
            "1.3.5",
            "1.3.4",
            "1.3.3",
            "1.3.2",
            "1.3.1",
            "1.3.0",
            "1.2.11",
            "1.2.10",
            "1.2.9",
            "1.2.8",
            "1.2.7",
            "1.2.6",
            "1.2.5",
            "1.2.4",
            "1.2.3",
            "1.2.2",
            "1.1",
            "1.0.2",
            "1.0.1",
            "1.0",
            "1.0b7",
            "1.0b6"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-54503.json"
          }
        }
      ],
      "modified": "2026-10-28T02:30:29.932506934Z",
      "provider": "osv",
      "references": [
        "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/54xxx/CVE-2026-54503.json",
        "https://github.com/plone/plone.app.textfield/security/advisories/GHSA-4r4f-gg25-rmg5",
        "https://nvd.nist.gov/vuln/detail/CVE-2026-54503",
        "https://github.com/plone/plone.app.textfield/commit/0da1aeec2406cf640977eb857a03e792d2c7cac2",
        "https://github.com/plone/plone.app.textfield/commit/467638e500d804c637031387a227a2b02d12a86f",
        "https://github.com/plone/plone.app.textfield/commit/781d517a38524087fe57525a94806684908f852f"
      ],
      "provider_metadata": {
        "cwe_ids": [
          "CWE-80"
        ],
        "cna_assigner": "GitHub_M",
        "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/54xxx/CVE-2026-54503.json"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2026-54503",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 496697,
  "published_at": "2026-09-15T16:38:38.29+00:00"
}