Authentication On Its Own
August 20th, 2008
So, recently I implemented Restful Authentication using the Restful Authentication with all the bells and whistles tutorial.
So far so good.
Now we find ourselves wanting to pull out user authentication into a separate database. Why would we want to do this non-Railsy thing? Well there’s loads of good reasons.
I’m a little annoyed by the attitude of some that accessing multiple databases is a bad thing. It’s a realistic thing, people. Sometimes I get the feeling that Rails folks are a little inexperienced when it comes to databases.
If RoR is ever to be accepted in big-name companies, folks will need to acknowledge that you just don’t always have the luxury of writing an app or creating a database from scratch. Specifically, there are many Enterprise Solutions designed so that login and user information is stored in its own database and accessed by multiple applications each having their own databases.
So what’s the best way to implement this model in Rails? I’ve tried just accessing the authentication models from a seperate db a la Recipe #15 from Rails Recipes. But this just seems to confuse the Mailer. I’ll blog again if I can get any further.
We’ve been thinking about playing with ActiveResource. Maybe we’ll create a stand alone Security App that can be accessed by our various web apps. A colleague came across an interesting blog post Authenticate like SSO with ActiveResource. Of course, this article pointed us towards RubyCAS which looks really fun.
Any thoughts?
Entry Filed under: Ruby on Rails

Leave a Comment
Some HTML allowed:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>
Trackback this post | Subscribe to the comments via RSS Feed