plataformatec/devise — Issue #1401: Devise, iFrame facebook apps & third party cookies
Author: josegrad
Created: 2011-10-26 17:18:21+00:00
State: open

Hi,

I have a Facebook app done with Rails. As FB apps run inside an iframe third party cookies are an issue. Handling of third party cookies also varies between browsers.

I thought I mostly fixed the issue by using the 'rack-p3p' gem:
config.middleware.insert_before ActionDispatch::Session::CookieStore, Rack::P3p

In fact I have third party cookies blocked in Safari and my app works ok. Today I found out that Chrome was failing after the latest update. So I need to look at it again.

The app runs inside an iFrame and the cookie on which devise (or Warden?) relies to find the logged in user is not found.
What is the correct approach to this problem?

Some time ago I tried to used memcached or even DB as session storage instead of cookies but if I remember correctly Warden was only supporting cookies.

I should fix the issue, I would appreciate a lot some suggestion about the best approach.

Regards,

Jose