samesite::none
This commit is contained in:
parent
c43f3f8e0e
commit
deb327e791
@ -25,7 +25,7 @@ use payments::{stripe};
|
||||
|
||||
pub const TOKEN_HEADER: &str = "x-auth-token";
|
||||
pub const AUTH_CLEAR: &str =
|
||||
"x-auth-token=; HttpOnly; SameSite=Strict; Path=/; Max-Age=-1;";
|
||||
"x-auth-token=; HttpOnly; SameSite=None; Path=/; Max-Age=-1;";
|
||||
|
||||
#[derive(Clone, Copy, Fail, Debug, Serialize, Deserialize)]
|
||||
pub enum MnmlHttpError {
|
||||
@ -191,7 +191,7 @@ impl AfterMiddleware for ErrorHandler {
|
||||
fn token_res(token: String) -> Response {
|
||||
let v = Cookie::build(TOKEN_HEADER, token)
|
||||
.http_only(true)
|
||||
.same_site(SameSite::Strict)
|
||||
.same_site(SameSite::None)
|
||||
.path("/")
|
||||
.max_age(Duration::weeks(1)) // 1 week aligns with db set
|
||||
.finish();
|
||||
@ -354,7 +354,7 @@ fn recover(req: &mut Request) -> IronResult<Response> {
|
||||
|
||||
let v = Cookie::build(TOKEN_HEADER, token)
|
||||
.http_only(true)
|
||||
// .same_site(SameSite::Strict)
|
||||
.same_site(SameSite::None)
|
||||
.path("/")
|
||||
.max_age(Duration::weeks(1)) // 1 week aligns with db set
|
||||
.finish();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user