How to disable secret_token in Rails 3?
- by Damian Nowak
I have several separate Rails 2 applications which share the same cookie. I upgraded one the applications to Rails 3.2.15 now. Mandatory secret_token in Rails 3 makes it impossible to share the session with the Rails 2 apps.
I am storing the session in Redis. What the visitor only gets in the cookie is a session ID. There's no need to encrypt it.
Therefore, how to disable secret_token in Rails 3?
A secret is required to generate an integrity hash for cookie session data. Use config.secret_token = "some secret phrase of at least 30 characters"in config/initializers/secret_token.rb