How to set SameSite cookie attribute using Apache configuration?

前端 未结 2 764
耶瑟儿~
耶瑟儿~ 2021-01-07 01:09

I am not able to see SameSite=Strict using builtin developer tools in the “Application” tab.

I have added below Header code in Apache configuration

H         


        
2条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2021-01-07 01:41

    For apache2 >= 2.2.4

    Header edit Set-Cookie ^(.*)$ $1;HttpOnly;Secure;SameSite=Strict
    

    For apache2 lower than 2.2.4

    Header set Set-Cookie HttpOnly;Secure;SameSite=Strict
    

提交回复
热议问题