exxocism / questions-codestates-seb

AMA πŸ˜‰
3 stars 0 forks source link

SameSite κ΄€λ ¨ #4

Open exxocism opened 1 year ago

exxocism commented 1 year ago

TBD

exxocism commented 1 year ago

@HyerimKimm

exxocism commented 1 year ago

@HyerimKimm μ•ˆλ…•ν•˜μ„Έμš”! Same-Site κ΄€λ ¨ν•˜μ—¬ 쒀더 확인해 λ³΄μ•˜μŠ΅λ‹ˆλ‹€. κ²°λ‘ λΆ€ν„° λ§μ”€λ“œλ¦¬λ©΄ λ‹€μŒκ³Ό κ°™μŠ΅λ‹ˆλ‹€.

1. `Schemeful Same-Site` κ·œμΉ™μ— λ”°λ₯΄λ©΄ http://localhost 와 https://localhost λŠ”  `Cross-Site`이닀.
2. https://auth-front.ngrok.app κ³Ό https://auth-back.ngrok.app λŠ”  `Cross-Site`이닀.
3. Same-Site와 Same-Origin의 μ°¨μ΄λŠ” λ‹€ λ˜‘κ°™κ³  포트만 λ‹€λ₯Έ κ²½μš°μ— μ μš©λœλ‹€.
4. Chrome의 `Sec-Fetch-Site` 헀더λ₯Ό 톡해 μ—°κ²°ν•˜λ €λŠ” μ‚¬μ΄νŠΈκ°€ μ–΄λ–»κ²Œ μ μš©λ˜λŠ”μ§€ μ•Œ 수 μžˆλ‹€.

If a request originates from a different domain or scheme (even with the same domain), no cookies with the SameSite=Strict attribute are sent.

=> Schemeful Same-Site κ·œμΉ™μ— λ”°λ₯΄λ©΄ http://localhost 와 https://localhost λŠ” Cross-Site이닀.

=> κ²°λ‘  : Same-Site와 Same-Origin의 μ°¨μ΄λŠ” λ‹€ λ˜‘κ°™κ³  포트만 λ‹€λ₯Έ κ²½μš°μ— μ μš©λœλ‹€.

=> Chrome의 Sec-Fetch-Site 헀더λ₯Ό 톡해 μ—°κ²°ν•˜λ €λŠ” μ‚¬μ΄νŠΈκ°€ μ–΄λ–»κ²Œ μ μš©λ˜λŠ”μ§€ μ•Œ 수 μžˆλ‹€.