Using OpenID with Authlogic - ruby-on-rails

Are there any updated tutorials for using OpenID with Authlogic? I'd heard good things about Authlogic, and the documentation makes it seem much better than Restful Authentication... but in trying to implement OpenID, 100% of the tutorials and information I've come across have been outdated (including Railscast #170). They depend on gems that either no longer work or no longer exist. And to add to the frustration, Github has been down for hours today.
Does anyone know of a simple updated guide to get OpenID working with Authlogic? Thanks!

The solution (if you're on Rails 2.3.8 like I am) is to use older versions of pretty much everything. I fond this app and simply copied the versions of the gems they were using: https://github.com/holden/authlogic_openid_selector_example. That meant using the authlogic_openid plugin rather than the gem form.
Things worked well after that.

Related

How to setup facebook-connect for authlogic in rails3?

I have been searching a lot on the net to get facebook-connect integrated with authlogic in rails3. There are a number of solutions based on facebooker, oauth etc. but none of them seem to say anything on whether they work with rails 3 or not. Can anyone guide to me on how to get facebook-connect working with authlogic in "rails3". I see that there are a lot of questions related to this on the site but none seems to have actually answered the question.
I strongly recommend you to use http://www.janrain.com/products/engage with this gem https://github.com/tardate/authlogic_rpx. This combo works amazing with two of my projects and it is free if you only want to use authentication (like in my case).
PS. look at railscast: http://railscasts.com/episodes/233-engage-with-devise. I know that, this podcast show how to use Janrain with Devise, but it helped me with Authlogic so it also can help you.

Why is AuthLogic so popular?

It seems that a lot of Ruby on Rails questions are related to AuthLogic. What are the advantages of it that it is so popular?
It's popular because with Rails 2.2, it was the most complete authentication plugin system.
The authentication is often the base of each web application. It's quickly used on a lot of projects and often beginners start by blindly adding the authlogic plugin. The beginner doesn't understand how it's works, and ask some questions on SO.
There is a new, great, and complete plugin for Rails 2.2 and Rails 3. It's called devise. A lot of people come with questions about it as well.
Each plugin is good, each is different. You just need to choose what you want.
There are a few self-contained user frameworks, and AuthLogic is one of the earliest full-featured varieties. Thoughtbot is also pretty good at marketing their technology, and their other gem, Paperclip, is very popular as well.
The advantage of AuthLogic is that you can get slap on a user authentication system quite easily to an existing application without having to roll your own, something that is challenging for someone unfamiliar with Rails.
Because it works.

Recommended twitter gem for ruby-on-rails

I've found a couple of different twitter gem (for ruby-on-rails) out there:
http://twitter4r.rubyforge.org/
http://twitter.rubyforge.org/
But I'm wondering if someone can rate them and provide a recommendation of either one or a new one.
Thanks
Use twitter. It's actively maintained.
I've used both twitter4r and twitter (outside of Rails though) and over time seem to have stuck with the latter since I find it easy to use and well documented.
Grackle http://github.com/hayesdavis/grackle is pretty good. It's very clean, actively developed and well documented. It supports both Basic and OAuth authentication.

Rails authentication plugin recommendation

I would like to add authentication to my Rails app. I came across few plugins that do this: acts_as_authenticated, restful_authentication, Authlogic...etc
I haven't seen an article that describes differences, advantages and disadvantages of using each.
Can you help with that? which one do you use and why?
Thanks,
Tam
I recently switched from restful_authentication to AuthLogic. The main reason was because I found restful_authentication a bit too bloated for what I was trying to achieve. Check out Ryan Bates' brilliant screencast:
http://railscasts.com/episodes/160-authlogic
I've switched from restful_authentication to Authlogic, because Authlogic is a plugin/gem as opposed to a generator. This makes it infinitely easier to upgrade.
Authlogic is also geared around being extensible, so you can fairly easily use it with OAuth or Facebook Connect (there are Authlogic modules that implement this, but I'm not using them; it's super easy to create an Authlogic user session manually).
Stay away from acts_as_authenticated. It's ancient and unmaintained. As noted, restful_authentication is its successor.
I'm a bit late to this party, but Devise looks pretty good. I'm using it on a project after trying AuthLogic. There's a couple of railscasts on it as well. I like it so far...definitely worth a look.
http://github.com/plataformatec/devise
I personally tend to use restful_authentication out of habit, but I've made use of AuthLogic a few times. AuthLogic is a lot leaner and cleaner code and tends to be much easier to setup and integrate into a project. It is also is newer and more popular (or feels like it as of late), so it should be easier to find resources or help if you need it. I'd definitely go AuthLogic.
If you'd like to know more about restful_authentication and see how it varies from AuthLogic in practice, there is also a railscast for it.
http://railscasts.com/episodes/67-restful-authentication
If you are looking for alternatives to the standard username/password scheme and using only external identity providers, there is a new plugin called OmniAuth that works at the rack level (so it's independent from Ruby on rails) and supports multiple external identity providers like OAuth, Facebook Connect, Google and LDAP.
There are also two Railscast episodes on how to use it: Episode 1 and Episode 2
If I am correct, restful_authentication is the succesor of acts_as_authenticated. I would therefore strongly disrecommend using acts_as_authenticated.
I personally use restful_authentication. It just works the way I expect it to work...
There's also thoughtbot's clearance. Though I chose Authlogic because of the authlogic-oid open id "add-on" gem.

How do I use open id in ruby on rails?

There doesn't appear to be any recent information about using Open ID in Ruby on Rails... the only walkthroughs that I can find do not work anymore. Does anyone know of a walkthrough or documentation that will actually work with modern versions of ruby on rails and required software?
I've been struggling with this for days and cannot make anything work.
This screencast is well done and fairly recent (july 2009):
Railscast on openid with authlogic
I found the early OpenID Railscast (68) really useful when I implemented OpenID, as well as Dan Webb's guide.

Resources