Solution to the problem that Google Chrome and Microsoft Edge browser versions 91 do not carry cookies

Foreword:

Recently, some single sign-on projects always refresh the page after being started locally. Looking at the network, I found that the login interface does not carry cookies, causing the login interface of the locally started project to always get 302. Originally, by accessing chrome://flags/, search for SameSite
Insert image description here
by Default cookies and setting them to disabled can solve the problem of cookie portability, but when I went in, I found that the SameSite by default cookies were gone. Later, I checked and found that both Google Chrome and Microsoft Edge browsers had been updated, causing the SameSite by default cookies to be removed.

solution:

  • Right-click the Google Chrome and Microsoft Edge browser shortcuts and click "Properties"
  • At the end of "Target(T)" add
 --flag-switches-begin --disable-features=SameSiteByDefaultCookies,CookiesWithoutSameSiteMustBeSecure --flag-switches-end

Insert image description here

Reference: https://gadzan.com/chrome-edge-91hou

Guess you like

Origin blog.csdn.net/qq_32881447/article/details/117747006