GHSA-8QJ2-C6Q4-F399

Vulnerability from github – Published: 2026-08-20 18:42 – Updated: 2026-08-20 18:42
VLAI
Summary
django CMS: Missing authorization in `render_object_structure` discloses non-PageContent placeholder structure to low-privileged staff
Details

Summary

The django-cms frontend-editing structure endpoint

GET /<lang>/admin/cms/placeholder/object/<content_type_id>/structure/<object_id>/

did not perform an object-level authorization check for non-PageContent objects. Any authenticated, active staff user could request the structure endpoint for a frontend-editable object (a model using PlaceholderRelationField) and read its placeholder/plugin structure, even without permission to change that object and without the cms.use_structure permission that the toolbar UI requires before offering structure mode.

PageContent objects were already protected (a page-view check added in GHSA/PR #8644); this advisory covers the remaining non-PageContent branch of the same view.

Severity

The issue is staff-gated and read-only, disclosing CMS structure metadata (placeholder slot names, plugin tree, plugin identifiers/labels, object existence) rather than write access or arbitrary field data.

Affected versions

  • django-cms >= 4.0.0, <= 5.0.x and 5.1.0a1 (the vulnerable non-PageContent branch was introduced with the frontend-editing endpoints in 4.0)

Patched versions

  • django-cms TODO: 5.0.9

Preconditions

  • An authenticated, active staff account (is_staff=True).
  • The deployment exposes a non-PageContent model with django-cms placeholders / frontend editing (e.g. via PlaceholderRelationField).
  • The attacker can guess or enumerate the target content_type_id and object id.
  • The attacker needs no model/object change permission and no cms.use_structure permission.

Impact

A low-privileged staff user can read the editorial placeholder/plugin structure of non-PageContent objects they are not authorized to edit through the toolbar. Depending on the installed plugins and templates this may reveal placeholder names, plugin layout, plugin identifiers and the existence of objects owned by other staff users or teams. This is most relevant for deployments using third-party or custom django-cms apps that expose frontend-editable objects outside the page tree.

Proof of concept

Using django-cms' own test model placeholder_relation_field_app.FancyPoll (a non-PageContent model with a PlaceholderRelationField):

target = FancyPoll.objects.create(name="private-fancy-poll")
placeholder = rescan_placeholders_for_obj(target)["content"]
attacker = self._create_user("low_staff", is_staff=True, is_superuser=False)
# attacker has neither change_fancypoll nor cms.use_structure

with self.login_user_context(attacker):
    response = self.client.get(get_object_structure_url(target, language="en"))

# Before fix: HTTP 200, body contains '"placeholder_id": "<pk>"'
# After fix:  HTTP 404, structure not disclosed

Patch

render_object_structure now authorizes the non-PageContent branch, mirroring Placeholder.has_change_permission at the object level (honouring a custom has_placeholder_change_permission hook, otherwise falling back to the model/object change permission) and returning 404 when the user is not authorized:

else:
    content_type_obj = content_type.get_object_for_this_type(pk=object_id)
    if not _can_change_placeholder_object(request.user, content_type_obj):
        raise Http404

Workarounds

No configuration workaround. Deployments that do not register any non-PageContent frontend-editable model are not affected. Otherwise, upgrade to a patched release.

Credit

Reported by doanmanhducz.

Show details on source website

{
  "affected": [
    {
      "package": {
        "ecosystem": "PyPI",
        "name": "django-cms"
      },
      "ranges": [
        {
          "events": [
            {
              "introduced": "0"
            },
            {
              "fixed": "5.0.9"
            }
          ],
          "type": "ECOSYSTEM"
        }
      ]
    }
  ],
  "aliases": [
    "CVE-2026-61663"
  ],
  "database_specific": {
    "cwe_ids": [
      "CWE-639",
      "CWE-862"
    ],
    "github_reviewed": true,
    "github_reviewed_at": "2026-08-20T18:42:50Z",
    "nvd_published_at": null,
    "severity": "MODERATE"
  },
  "details": "## Summary\n\nThe django-cms frontend-editing structure endpoint\n\n```\nGET /\u003clang\u003e/admin/cms/placeholder/object/\u003ccontent_type_id\u003e/structure/\u003cobject_id\u003e/\n```\n\ndid not perform an object-level authorization check for **non-`PageContent`** objects. Any authenticated, active staff user could request the structure endpoint for a frontend-editable object (a model using `PlaceholderRelationField`) and read its placeholder/plugin structure, even without permission to change that object and without the `cms.use_structure` permission that the toolbar UI requires before offering structure mode.\n\n`PageContent` objects were already protected (a page-view check added in GHSA/PR #8644); this advisory covers the remaining non-`PageContent` branch of the same view.\n\n## Severity\n\nThe issue is staff-gated and read-only, disclosing CMS structure metadata (placeholder slot names, plugin tree, plugin identifiers/labels, object existence) rather than write access or arbitrary field data.\n\n## Affected versions\n\n- django-cms `\u003e= 4.0.0, \u003c= 5.0.x` and `5.1.0a1`\n  (the vulnerable non-`PageContent` branch was introduced with the frontend-editing endpoints in 4.0)\n\n## Patched versions\n\n- django-cms TODO: 5.0.9\n\n## Preconditions\n\n- An authenticated, active staff account (`is_staff=True`).\n- The deployment exposes a non-`PageContent` model with django-cms placeholders / frontend editing (e.g. via `PlaceholderRelationField`).\n- The attacker can guess or enumerate the target `content_type_id` and object id.\n- The attacker needs **no** model/object change permission and **no** `cms.use_structure` permission.\n\n## Impact\n\nA low-privileged staff user can read the editorial placeholder/plugin structure of non-`PageContent` objects they are not authorized to edit through the toolbar. Depending on the installed plugins and templates this may reveal placeholder names, plugin layout, plugin identifiers and the existence of objects owned by other staff users or teams. This is most relevant for deployments using third-party or custom django-cms apps that expose frontend-editable objects outside the page tree.\n\n## Proof of concept\n\nUsing django-cms\u0027 own test model `placeholder_relation_field_app.FancyPoll` (a non-`PageContent` model with a `PlaceholderRelationField`):\n\n```python\ntarget = FancyPoll.objects.create(name=\"private-fancy-poll\")\nplaceholder = rescan_placeholders_for_obj(target)[\"content\"]\nattacker = self._create_user(\"low_staff\", is_staff=True, is_superuser=False)\n# attacker has neither change_fancypoll nor cms.use_structure\n\nwith self.login_user_context(attacker):\n    response = self.client.get(get_object_structure_url(target, language=\"en\"))\n\n# Before fix: HTTP 200, body contains \u0027\"placeholder_id\": \"\u003cpk\u003e\"\u0027\n# After fix:  HTTP 404, structure not disclosed\n```\n\n## Patch\n\n`render_object_structure` now authorizes the non-`PageContent` branch, mirroring\n`Placeholder.has_change_permission` at the object level (honouring a custom\n`has_placeholder_change_permission` hook, otherwise falling back to the model/object\nchange permission) and returning `404` when the user is not authorized:\n\n```python\nelse:\n    content_type_obj = content_type.get_object_for_this_type(pk=object_id)\n    if not _can_change_placeholder_object(request.user, content_type_obj):\n        raise Http404\n```\n\n## Workarounds\n\nNo configuration workaround. Deployments that do not register any non-`PageContent`\nfrontend-editable model are not affected. Otherwise, upgrade to a patched release.\n\n## Credit\n\nReported by **doanmanhducz**.",
  "id": "GHSA-8qj2-c6q4-f399",
  "modified": "2026-08-20T18:42:50Z",
  "published": "2026-08-20T18:42:50Z",
  "references": [
    {
      "type": "WEB",
      "url": "https://github.com/django-cms/django-cms/security/advisories/GHSA-8qj2-c6q4-f399"
    },
    {
      "type": "WEB",
      "url": "https://github.com/django-cms/django-cms/pull/8703"
    },
    {
      "type": "WEB",
      "url": "https://github.com/django-cms/django-cms/commit/9c82abfeb25471583e23906ea1ebef9202527b04"
    },
    {
      "type": "PACKAGE",
      "url": "https://github.com/django-cms/django-cms"
    },
    {
      "type": "WEB",
      "url": "https://github.com/django-cms/django-cms/releases/tag/5.0.9"
    }
  ],
  "schema_version": "1.4.0",
  "severity": [
    {
      "score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N",
      "type": "CVSS_V3"
    }
  ],
  "summary": "django CMS: Missing authorization in `render_object_structure` discloses non-PageContent placeholder structure to low-privileged staff"
}



Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Forecast uses a logistic model when the trend is rising, or an exponential decay model when the trend is falling. Fitted via linearized least squares.

Sightings

Author Source Type Date Other

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or observed by the user.
  • Confirmed: The vulnerability has been validated from an analyst's perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
  • Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
  • Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
  • Not confirmed: The user expressed doubt about the validity of the vulnerability.
  • Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.

Loading…

Detection rules are retrieved from Rulezet.

Loading…

Loading…

Loading…