Disable Same-Site cookie implementation to fix SSO issues on WebKit browsers (#9819)
This commit is contained in:
parent
a12f6d10cc
commit
ecf40d09ed
@ -10,7 +10,6 @@ Warden::Manager.after_set_user except: :fetch do |user, warden|
|
|||||||
expires: 1.year.from_now,
|
expires: 1.year.from_now,
|
||||||
httponly: true,
|
httponly: true,
|
||||||
secure: (Rails.env.production? || ENV['LOCAL_HTTPS'] == 'true'),
|
secure: (Rails.env.production? || ENV['LOCAL_HTTPS'] == 'true'),
|
||||||
same_site: :lax,
|
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -21,7 +20,6 @@ Warden::Manager.after_fetch do |user, warden|
|
|||||||
expires: 1.year.from_now,
|
expires: 1.year.from_now,
|
||||||
httponly: true,
|
httponly: true,
|
||||||
secure: (Rails.env.production? || ENV['LOCAL_HTTPS'] == 'true'),
|
secure: (Rails.env.production? || ENV['LOCAL_HTTPS'] == 'true'),
|
||||||
same_site: :lax,
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
warden.logout
|
warden.logout
|
||||||
|
@ -1,3 +1,3 @@
|
|||||||
# Be sure to restart your server when you modify this file.
|
# Be sure to restart your server when you modify this file.
|
||||||
|
|
||||||
Rails.application.config.session_store :cookie_store, key: '_mastodon_session', secure: (Rails.env.production? || ENV['LOCAL_HTTPS'] == 'true'), same_site: :lax
|
Rails.application.config.session_store :cookie_store, key: '_mastodon_session', secure: (Rails.env.production? || ENV['LOCAL_HTTPS'] == 'true')
|
||||||
|
@ -29,7 +29,6 @@ Devise::Test::ControllerHelpers.module_eval do
|
|||||||
value: resource.activate_session(warden.request),
|
value: resource.activate_session(warden.request),
|
||||||
expires: 1.year.from_now,
|
expires: 1.year.from_now,
|
||||||
httponly: true,
|
httponly: true,
|
||||||
same_site: :lax,
|
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user