Register for the AI for Security Summit: Join Figma, Perplexity & Wiz

CVE-2026-61597
Python vulnerability analysis and mitigation

Overview

CVE-2026-61597 is a stored/reflected Cross-Site Scripting (XSS) vulnerability in djust, a Phoenix LiveView-style reactive server-side rendering framework for Django with Rust-powered performance. The flaw affects all versions of djust prior to 1.0.7 and was first published on June 22, 2026, with the advisory added to the GitHub Advisory Database on September 16, 2026. Multiple built-in component template tags (djust.components.templatetags.*) render user-supplied URLs into href and action attributes without validating the URL scheme, allowing javascript: URIs to execute in victims' browsers. The vulnerability carries a CVSS v4.0 base score of 5.1 (Medium) (GitHub Advisory, GHSA Advisory).

Technical details

The root cause is CWE-79 (Improper Neutralization of Input During Web Page Generation — Cross-Site Scripting): affected template tags apply Django's conditional_escape to user-supplied URLs, which prevents HTML attribute breakout but does not neutralize javascript: URIs since they contain no characters requiring HTML escaping. Affected sinks include breadcrumb links (djust_components.py:1535; _advanced.py:1999,2022), navigation links/dropdowns/brand (djust_components.py:5632,5779,5807,5830), citation URLs (:6936), cookie-consent privacy links (:8240), error-page actions (_advanced.py:1728), and form actions (_forms.py:1239). Notably, a docstring at djust_components.py:781 acknowledged the javascript: risk without implementing any mitigation. Case variants such as JaVaScRiPt: also bypass the non-existent scheme validation, and exploitation requires only that a low-privileged user can supply a URL value that is later rendered to another user (GitHub Advisory, GHSA Advisory).

Impact

Successful exploitation allows an attacker to execute arbitrary JavaScript in the authenticated session of any victim who clicks a maliciously crafted link rendered by an affected component. The worst-case scenario is the stored variant, where a malicious URL persisted by one user is rendered to other users, enabling session hijacking, credential theft, and unauthorized actions performed on behalf of the victim. While the vulnerable system itself has no direct confidentiality or integrity impact, the subsequent system impact includes low-level confidentiality and integrity compromise (e.g., cookie exfiltration, DOM manipulation) (GitHub Advisory, GHSA Advisory).

Exploitability

No public proof-of-concept exploit code has been published, and there is no evidence of in-the-wild exploitation as of the advisory date. The EPSS score is 0.0, indicating a very low current probability of exploitation in the wild, and the vulnerability is not listed in the CISA Known Exploited Vulnerabilities (KEV) catalog. Exploitation requires a low-privileged attacker who can supply a URL to an affected component, plus passive user interaction (a victim clicking the link), limiting the attack surface to applications that pass user-controllable URLs to djust's built-in component tags (GitHub Advisory).

Exploitation steps

  1. Identify a target application: Locate a Django application using djust (pip package) version < 1.0.7 that renders user-supplied URLs through built-in component template tags such as breadcrumbs, navigation links, forms, or error pages.
  2. Supply a malicious URL: As a low-privileged authenticated user, submit a javascript: URI as a URL value to an affected component — for example, providing javascript:alert(document.cookie) as a breadcrumb item URL or form action URL via any user-controllable input field.
  3. Trigger rendering: Ensure the malicious URL is stored (stored XSS) or reflected in a page rendered to other users. For example: breadcrumb(items=[{"label":"Home","url":"javascript:alert(document.cookie)"}]) emits <a href="javascript:alert(document.cookie)">Home</a>.
  4. Bypass case-sensitivity checks: If any application-level filtering exists, use mixed-case variants such as JaVaScRiPt:alert(document.cookie) to evade naive string matching.
  5. Achieve payload execution: When a victim (e.g., another authenticated user or administrator) clicks the rendered link, the javascript: URI executes in their browser session, enabling cookie theft, session hijacking, or further malicious actions (GitHub Advisory, GHSA Advisory).

Indicators of compromise

  • Logs: Web server or Django application logs showing URL parameters or form fields containing javascript:, vbscript:, or data: scheme strings submitted to endpoints that feed djust component tags.
  • Database/Storage: Stored records (e.g., breadcrumb items, navigation entries, form action fields) containing javascript: or mixed-case variants like JaVaScRiPt: in URL fields.
  • Network: Outbound requests from victim browsers to attacker-controlled infrastructure (e.g., cookie exfiltration endpoints) originating shortly after page loads containing djust-rendered components.
  • Browser/Client: Unexpected JavaScript execution alerts or console errors triggered on pages rendering djust breadcrumb, navigation, form, or error-page components with user-supplied URL data (GitHub Advisory).

Mitigation and workarounds

Upgrade djust to version 1.0.7, which introduces a safe_url() helper that neutralizes non-allowlisted schemes (javascript:, vbscript:, data:) by replacing them with #, while preserving http, https, mailto, tel, relative, and anchor URLs. All href, action, formaction, and xlink:href sinks are routed through this helper before HTML escaping. As a workaround for those unable to upgrade immediately, do not pass user-controllable URLs to the affected built-in component tags, and pre-validate URL schemes in application code before binding them to component arguments (GitHub Advisory, v1.0.7 Release).

Additional resources


SourceThis report was generated using AI

Related Python vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2026-61599HIGH8.8
  • Python logoPython
  • djust
NoYesSep 16, 2026
CVE-2026-61596HIGH7.1
  • Python logoPython
  • djust
NoYesSep 16, 2026
CVE-2026-61588MEDIUM6.5
  • Python logoPython
  • djust
NoYesSep 16, 2026
CVE-2026-61589MEDIUM6.3
  • Python logoPython
  • djust
NoYesSep 16, 2026
CVE-2026-61597MEDIUM5.1
  • Python logoPython
  • djust
NoYesSep 16, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management