A webhook sends its stored secret headers to a changed URL, and a NUL byte in an answer repeats the delivery

Abierto
#3,299 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
55/100
Tipo de issue
Error
Claridad
Bien especificado
Estado de actividad
Activo
Stack tecnológico
csharp, postgresql

Línea de trabajo

Start with WebhookService.cs around lines 139, 353, and 424 to trace how masked headers are retained when a URL changes. Then read WebhookSender.cs around lines 96–107 and WebhookDeliveryJob.cs around lines 68–78 and 186–207 to follow answer storage and retry handling. Add regression tests for both acceptance cases and verify that a 2xx response containing a NUL byte is recorded as one successful delivery across providers.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

plugin security type:bug

Problem

  1. A kept *** header follows a changed URL. src/plugins/FluentCMS.Plugins.Webhooks/WebhookService.cs:139,353 keep the stored value for a header sent as *** without checking that the URL is unchanged (applied at :424). A webhooks.manage holder can repoint the webhook to a host of their own and receive headers that are write-only.
  2. An answer containing a NUL byte is delivered six times and dead-lettered on PostgreSQL. WebhookSender.cs:96-107 stores up to 4 KB of the answer as received, and WebhookDeliveryJob.cs:68-78 writes it to a text column, which PostgreSQL refuses for 0x00. The job throws after a 2xx, TakeOverAsync (:186-207) marks the attempt interrupted and schedules the next. The receiver gets duplicates, a WebhookDeadEvent is raised, and the webhook is disabled when DisableAfter is set. This was read from the code, not reproduced.

Proposal

  • Refuse *** when the scheme, host or port of the URL changes; the caller must send the value again.
  • Strip control characters from the stored excerpt.

Done together with #3268, which changes the same delivery job.

Acceptance

  • An update that changes the host and keeps a header as *** is refused with a problem naming the header
  • The same update with the URL unchanged, or only its path changed, keeps the header
  • A 2xx answer containing 0x00 is recorded as one successful delivery on every provider
  • Tests for each, failing before the fix

Found in the code review of 17 Nov 2026.

Lenguaje dominante
C#
Estrellas
569
Forks
107
Merge medio
2 h 49 min
PR fusionados (30 d)
397

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de fluentcms/FluentCMS

Todos los issues de fluentcms/FluentCMS

Issues similares

Más issues de C#

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.