views:

134

answers:

1

Rails is setting and returning a remember_token cookie like this:

= cookies[:remember_token] 
= value6c69b17681d2bf316f8eexpiresThu Jun 10 14:55:00 -0400 2010

In other words, when I'm calling the cookie I don't just get the value. Why is this?

I am setting the cookie as follows:

cookies[:remember_token] = { :value => @user.remember_me, :expires => 1.year.from_now}

What's going on here?

A: 

I can confirm this problem as well. I'm on Rails 2.3.8. Using cookies.permanent[:remember_token] = value works, however (with proper expiration set). Looks like it is related to the cookie add-ons included in 2.3.6 http://github.com/rails/rails/commit/0200e20f148c96afceeebc4da7b5985643f9f707

senihele