Webapp session management in Chrome Extensions

26 views
Skip to first unread message

J.Chung

unread,
Nov 10, 2011, 10:56:17 AM11/10/11
to chromium-...@chromium.org
When building a chrome extension which loads content from a webapp (built in this case on Django, but also for Rails, etc.), it would be great to use the webapp framework's built-in session management system. However, I can't find a good way to receive a session cookie when the extension accesses the webapp. Is that a chrome limitation? Is that a limitation in AJAX (via JQuery which I'm using to .load() content from the webapp)? 

I've searched back through this message board, but nothing directly addresses the use of session cookies or other ways of authentication (Excluding OAuth which gets a mountain of attention?!). I'd appreciate any and all responses on how to do this well. Special kudos for answers specific to pairing an extension with a Django app. Super special kudos for answers with examples or links to tutorials. 

johnjbarton

unread,
Nov 11, 2011, 10:43:26 AM11/11/11
to Chromium-extensions


On Nov 10, 7:56 am, "J.Chung" <jaredch...@gmail.com> wrote:
> When building a chrome extension which loads content from a webapp (built
> in this case on Django, but also for Rails, etc.), it would be great to use
> the webapp framework's built-in session management system. However, I can't
> find a good way to receive a session cookie when the extension accesses the
> webapp. Is that a chrome limitation? Is that a limitation in AJAX (via
> JQuery which I'm using to .load() content from the webapp)?

How about loading your app into an iframe in the extn window? Then you
don't have to use the .load(). I do this in my extn and the cookie bit
seems to work, at least to the extent that I don't have to login in my
extn if logged in from the browser before the iframe loads.

jjb
Reply all
Reply to author
Forward
0 new messages