Two components:
- A React single page app on https://react.mycompany.com
- A Apigee API proxy on https://apigee.proxy.com
On login Apigee sets a jwt
cookie using the Set-Cookie
header:
Set-Cookie: jwt={jwtoken};secure;httponly;path=/;samesite=none
On client side Chrome shows me this cookie for the frame https://react.mycompany.com
:
name: jwt
value: XXX
domain: apigee.proxy.com
path: /
httpOnly: true
secure: true
sameSite: none
Now on non-auth requests Apigee checks the presence of the jwt
cookie before processing the request.
The cookie is not sent on the OPTIONS
preflight request and therefore all calls fail.
On client side we use the fetch()
API with credentials: 'include'
.
What am I missing here?