views:

71

answers:

4

I'm looking to build an application that handles authentication and authorization for a variety of smaller apps that may or may not be rails applications (e.g. some with sinatra, some with non-ruby frameworks, etc). These applications will be on separate domains.

Can I do this with Authlogic? I do not want to setup a rails application for each application, just use a central authenticator. I'm sure as I start reading and working the answer would become evident, but I'm trying to avoid a dead end (doing work and research, then finding out this can't be done.)

From what I've read this is a use case, and I'm looking for input from people who've done similar. This is at the idea stage so if i can offer more detail, let me know.

A: 

Today, the cool kids use warden, or the railsy thingy devise.

Tass
Warden/devise is considered too. In fact I looked there first, but found Authlogic today.
anastazja
A: 

Im not sure but i think you cant use authlogic with a non-ruby-app.

Lichtamberg
I know, I'm not actually attempting to weld apples and oranges together, just set up a central authenticator/authorizor
anastazja
+1  A: 

I think you are planning to build a cross domain, single sign-on service. Besides building your own, there are a quite a few project that do this out of the box. rubycas is one of them : http://code.google.com/p/rubycas-server/

You could also look into open Id (http://openid.net), where the login functionality is done by a third party authentication server.

In case you want to roll your own: It doesn't really matter which authentication plugin/system you will use. (I would choose devise/warden, but Authlogic will do just fine). Instead you need to focus on understanding the security problems and the http interaction between your service, the browser and the application for which authentication is used. I think it's doable, but you need to know what you are doing.

Mark Meeus
A: 

I would probably go with Devise as well but you should look into some plugins for it like JanRain's Engage (used to be RPX Now). It allows you to use quite a few social login options (Facebook, Twitter, etc.) http://www.janrain.com/products/engage.

Ryan Bates from Railscasts.com just posted an episode on Devise using Engage this morning. http://railscasts.com/episodes/233-engage-with-devise

There are some more episodes about Devise on Railscasts too. http://railscasts.com/episodes?search=devise

If I were you I wouldn't reinvent the wheel. I'd use a third party service to authenticate and just get on with the project. Social connectors such as Engage will provide this functionality for you without all the time and expertise.

Nate Bird