CVE-2026-39807

Reliance on Untrusted Inputs in a Security Decision vulnerability in mtrudel bandit allows unauthenticated transport-state spoofing on plaintext HTTP connections. 'Elixir.Bandit.Pipeline':determine_scheme/2 in lib/bandit/pipeline.ex returns the client-supplied URI scheme verbatim, ignoring the transport's secure? flag. HTTP/1.1 absolute-form request targets (e.g. GET https://victim/path HTTP/1.1) and the HTTP/2 :scheme pseudo-header are both attacker-controlled strings that flow through this function. Over a plaintext TCP connection, a client can declare https and Bandit will set conn.scheme = :https even though no TLS was negotiated. Downstream Plug consumers that branch on conn.scheme are silently misled: Plug.SSL's already-secure branch skips its HTTP→HTTPS redirect, cookies emitted with secure: true are sent over plaintext, audit logs record requests as having arrived over HTTPS, and CSRF/SameSite gating may make incorrect decisions. This issue affects bandit: from 1.0.0 before 1.11.0.
CVSS

No CVSS.

Configurations

No configuration.

History

26 Oct 2026, 21:10

Type Values Removed Values Added
Summary
  • (es) Una vulnerabilidad de Confianza en Entradas No Confiables en una Decisión de Seguridad en mtrudel bandit permite la suplantación de estado de transporte no autenticada en conexiones HTTP de texto plano. ’Elixir.Bandit.Pipeline’:determine_scheme/2 en lib/bandit/pipeline.ex devuelve el esquema URI proporcionado por el cliente textualmente, ignorando el indicador secure? del transporte. Los objetivos de solicitud de formulario absoluto HTTP/1.1 (p. ej., GET https://victim/path HTTP/1.1) y el pseudo-encabezado :scheme de HTTP/2 son ambas cadenas controladas por el atacante que fluyen a través de esta función. Sobre una conexión TCP de texto plano, un cliente puede declarar https y Bandit establecerá conn.scheme = :https incluso si no se negoció TLS. Los consumidores de Plug posteriores que se ramifican en conn.scheme son engañados silenciosamente: la rama ya segura de Plug.SSL omite su redirección de HTTP a HTTPS, las cookies emitidas con secure: true se envían en texto plano, los registros de auditoría registran las solicitudes como si hubieran llegado a través de HTTPS, y la restricción de CSRF/SameSite puede tomar decisiones incorrectas. Este problema afecta a bandit: desde 1.0.0 antes de 1.11.0.

Information

Published : 2026-05-01 21:16

Updated : 2026-10-26 21:10


NVD link : CVE-2026-39807

Mitre link : CVE-2026-39807

CVE.ORG link : CVE-2026-39807


JSON object : View

Products Affected

No product.

CWE
CWE-807

Reliance on Untrusted Inputs in a Security Decision