Is a Hash cookie entry possible?

Hello, I want to create a cookie that is a serialized Hash.

before_filter :cookie_criteres

def cookie_criteres
cookies[‘criteres’] = Hash.new if cookies[‘criteres’].nil?
end

But when, later in a view I want to retrieve the cookies[‘criteres’]
Hash Rails returns a CGI::Cookie instance object…

I don’t undestand how to do next - Should I cast this to a Hash (how ?)
? Is something else needed to serialize the Hash properly ?

Thanks