Analytics: cookie_sync and setuid events ignore analytics.global.adapters and account enabled flag

Abierto
#4,717 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 2 días

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
java

Línea de trabajo

Read AnalyticsReporterDelegator.isAllowedAdapter and its tests, then inspect CookieSyncEvent, SetuidEvent, and the two handlers that create those events. Trace how other event types carry account and activity infrastructure into adapter checks. Done when tests show cookie sync and setuid respect the global adapter list and, when an account is present, its enabled flag.

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

Descripción

🤖 This issue was written by an AI agent (Claude Code) on behalf of @patmmccann.

What happens

AnalyticsReporterDelegator.isAllowedAdapter checks analytics.global.adapters and the account's analytics.modules.<name>.enabled (isNotAllowedAdapterByGlobalOrAccountAnalyticsConfig) only for AuctionEvent, AmpEvent, NotificationEvent and VideoEvent. CookieSyncEvent and SetuidEvent fall through to the default branch, which skips that check and passes a null activity infrastructure, so the event is allowed:

As a result, every reporter bean that has been created gets cookie sync and setuid events. That includes reporters that are left out of analytics.global.adapters and reporters an account has turned off with "enabled": false. The only filter is the host-level TCF Purpose 7 check in processEvent(event, tcfContext).

The account is available in both handlers (SetuidContext.account, CookieSyncContext.account), but it isn't put on the events:

Why it matters

Functional and privacy. analytics.global.adapters and the account enabled flag are how hosts and publishers decide which reporters get data. If a publisher has turned a reporter off, that reporter could still get their users' cookie sync and setuid traffic, including the bidder UID on setuid (see https://github.com/prebid/prebid-server-java/issues/4718).

To reproduce

  1. Enable a reporter, e.g. pubstack.enabled: true, but leave it out of analytics.global.adapters. Or keep it in the list and set account acc1 to {"analytics": {"modules": {"pubstack": {"enabled": false}}}}.
  2. Call /cookie_sync with "account": "acc1", or /setuid?bidder=...&uid=...&account=acc1.
  3. The reporter's processEvent receives a CookieSyncEvent/SetuidEvent. A /openrtb2/auction request for the same account doesn't reach it.

Expected behaviour

Cookie sync and setuid events respect analytics.global.adapters, and the account-level enabled flag when an account is known, in the same way as the other event types.

Suggested fix

Add the Account (and ActivityInfrastructure, see https://github.com/prebid/prebid-server-java/issues/4718) to CookieSyncEvent and SetuidEvent, and add matching branches to isAllowedAdapter. At minimum, apply the globalEnabledAdapters check in the default branch.

References

🤖 Generated with Claude Code

Lenguaje dominante
Java
Estrellas
108
Forks
258
Merge medio
3 d 20 h
PR fusionados (30 d)
12

Preparar el entorno

Abrir en Codespaces

Inicia el contenedor de desarrollo del proyecto en tu navegador, con tu propia cuenta de GitHub.

  • Incluye un Dockerfile o un archivo de Docker Compose
  • Tiene una plantilla de pull request
  • Sin guía de contribución

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 prebid/prebid-server-java

Todos los issues de prebid/prebid-server-java

Issues similares

Más issues de Java

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.