MobileSafari won't send back Cookies set with CORS

后端 未结 5 732
臣服心动
臣服心动 2021-02-08 04:57

I have a page loading up in MobileSafari which communicated with another server via CORS.

In desktop browsers (tested Chrome and Safari), I am able to log in, get a sess

5条回答
  •  既然无缘
    2021-02-08 05:39

    I was running into the same problem.

    My setup was:

    • AngularJS (Ionic) App on Server A with domain a.com
    • NodeJS with Passport JS as Backend on Server B with domain b.com

    The login with the cookie went well on every browser, except Mobile Safari on iOS. Also the change of the mobile cookie (Do not track) settings in iOS did not had any impact on the issue.

    Solution was to set a CNAME DNS Record

    backend.a.com CNAME b.com

提交回复
热议问题