Skip to content

sentry-trace header being added to request to origin not in tracingOrigins #4411

@amosbastian

Description

@amosbastian

Package + Version

  • @sentry/browser
  • @sentry/node
  • raven-js
  • raven-node (raven for node)
  • other:
    • @sentry/nextjs

Version:

^6.16.1

Description

We have Sentry initialised with

browserTracingOptions: {
  tracingOrigins: ["localhost", "joinlifex.com", "herokuapp.com", "vercel.app"],
},

but despite this the sentry-trace header is still being added to an outgoing request to our cookie solution:

Access to XMLHttpRequest at 'http://cdn.iubenda.com/cs/tcf/v2/vendorlist.121.json' from origin 'http://localhost:3000' has been blocked by CORS policy: Request header field sentry-trace is not allowed by Access-Control-Allow-Headers in preflight response.

I am confused why the header is being added despite http://cdn.iubenda.com/cs/tcf/v2/vendorlist.121.json not being in the list of tracingOrigins, but I'm probably missing something obvious! 😖

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions