Zum Inhalt springen

SameSite=None Cookie (ARCH9136)

Dieser Inhalt ist noch nicht in deiner Sprache verfügbar.

Key swift.security.samesite-none-cookie · Severity warning · Category security · CWE CWE-1275

Flags HTTPCookies.Value(sameSite: .none) without isSecure: true - browsers reject the cookie and cross-site CSRF posture weakens.

HTTPCookies.Value(string: token, sameSite: .none)
HTTPCookies.Value(string: token, isSecure: true, isHTTPOnly: true, sameSite: .none)

Pass isSecure: true with sameSite: .none, or use .lax when cross-site is not required.