Skip to content

Commit

Permalink
Set Access-Control-Allow-Credentials: true in localserver (#1955)
Browse files Browse the repository at this point in the history
  • Loading branch information
RebeccaMahany authored Nov 13, 2024
1 parent d899593 commit 7dfbe72
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ee/localserver/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -381,6 +381,9 @@ func (ls *localServer) preflightCorsHandler(next http.Handler) http.Handler {
w.Header().Set("Access-Control-Allow-Headers",
"Accept, Content-Type, Content-Length, Accept-Encoding, X-CSRF-Token, Authorization")

// We need this for device trust to work in newer versions of Chrome with experimental features toggled on
w.Header().Set("Access-Control-Allow-Credentials", "true")

// Some modern chrome and derivatives use Access-Control-Allow-Private-Network
// https://developer.chrome.com/blog/private-network-access-preflight/
// Though it's unclear if this is still needed, see https://developer.chrome.com/blog/private-network-access-update/
Expand Down

0 comments on commit 7dfbe72

Please sign in to comment.