dns3l / dns3l-core

Core functionality of dns3l written in Go
1 stars 3 forks source link

CORS issues when using client-side web SPA #56

Open iaean opened 1 year ago

iaean commented 1 year ago

Developing SPA directly against dns3ld seems not possible. There is no CORS (preflight) implementation available for the Go HTTP endpoint.

https://stackoverflow.com/questions/22972066/how-to-handle-preflight-cors-requests-on-a-go-server

Dex e.g. provides a

web:
  allowedOrigins: ['*']

option to inject proper CORS headers into the response.

Actually trying to work around this with proxy config. But the backend needs CORS code to support REST via web clients/browsers.