---
id: CVE-2024-6961
aliases:
  - GHSA-f8hx-f4xw-c646
  - PYSEC-2026-1431
title: >-
  Guardrails AI vulnerable to Improper Restriction of XML External Entity
  Reference
summary: >-
  Guardrails AI vulnerable to Improper Restriction of XML External Entity
  Reference
severity: medium
cvss: 5.9
cvssVector: 'CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N'
vendor: guardrails-ai
product: guardrails-ai
ecosystem: pip
affected:
  - guardrails-ai < 0.5.0
patched:
  - guardrails-ai 0.5.0
published: '2024-07-21'
updated: '2026-07-07'
source: OSV
sourceUrl: 'https://osv.dev/vulnerability/GHSA-f8hx-f4xw-c646'
references:
  - url: 'https://nvd.nist.gov/vuln/detail/CVE-2024-6961'
  - url: 'https://github.com/guardrails-ai/guardrails/pull/922'
  - url: >-
      https://github.com/guardrails-ai/guardrails/commit/f3d806afee31e2e3f97af682d16c3c1bc0d3c380
  - url: 'https://github.com/guardrails-ai/guardrails'
  - url: >-
      https://research.jfrog.com/vulnerabilities/guardrails-rail-xxe-jfsa-2024-001035519
tags:
  - osv
  - pip
epss: 0.00408
epssPercentile: 0.34827
ingestedAt: '2026-07-08T18:25:48.845Z'
---

## Overview

RAIL documents are an XML-based format invented by Guardrails AI to enforce formatting checks on LLM outputs. Guardrails users that consume RAIL documents from external sources are vulnerable to XXE, which may cause leakage of internal file data via the SYSTEM entity.

## Affected packages

- `guardrails-ai < 0.5.0`

## Remediation

Upgrade to a patched release:

- `guardrails-ai 0.5.0`
