AuthLogic perishable_token resets on every request

后端 未结 1 536
感动是毒
感动是毒 2021-01-01 00:29

In my User model I have:

acts_as_authentic do |c|
  c.perishable_token_valid_for = 30.minutes
end

In my Application Controller I have the s

相关标签:
1条回答
  • 2021-01-01 00:50

    perishable_token_valid_for isn't doing what you think it is. It's intended to work in tandem with find_using_perishable_token which is intended for things like account validation and resetting a forgotten password. The default timeout is 10 minutes.

    The token is supposed to update on every request like it's doing. You can just remove the column if you don't want it. It's completely optional with authlogic.

    If you really do want to keep the perishable token but update it completely by hand, you can do disable_perishable_token_maintenance = true

    0 讨论(0)
提交回复
热议问题