Skip to content

Commit

Permalink
Mark cookies as secure
Browse files Browse the repository at this point in the history
This allows the samesite=none change in the last commit to work.
  • Loading branch information
atruskie committed Dec 20, 2024
1 parent 49533f2 commit 4165422
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 3 additions & 1 deletion config/initializers/devise.rb
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,9 @@

# Options to be passed to the created cookie. For instance, you can set
# :secure => true in order to force SSL only cookies.
# config.rememberable_options = {}
config.rememberable_options = {
secure: true
}

# ==> Configuration for :validatable
# Range for password length. Default is 8..128.
Expand Down
4 changes: 3 additions & 1 deletion config/initializers/session_store.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# frozen_string_literal: true

# Be sure to restart your server when you modify this file.

Rails.application.config.session_store :cookie_store, key: '_baw_session'
Rails.application.config.session_store :cookie_store, key: '_baw_session', secure: true

0 comments on commit 4165422

Please sign in to comment.