authlogic

authlogic current_user tracking

I use authlogic for authentication and paperclip for handling user's profile picture attachments. I use the following method to get the current_user def current_user_session return @current_user_session if defined? (@current_user_session) @current_user_session = UserSession.find end def current_user re...

extended permissions in authlogic facebooker plugin?

How does one request extended permissions? Adding a :perms key to the hash <%#= authlogic_facebook_login_button :text => 'Login with Facebook', :v => 2, :perms => "email,user_birthday" %> causes the FBML to render as <form id='connect_to_facebook_form' method='post' action='/user_session'> <input type='hidden' name='authenticity_to...

MongoDB and Authlogic, any gotchas? (mongomapper)

Authlogic, by itself, seems to be too active record centric for MongoDB (specifically mongomapper) as per: http://github.com/binarylogic/authlogic/issues#issue/15. However, there's an interesting authlogic plugin for mongo that looks pretty awesome, and simple. Has anyone used this, or have any experience/recommendations for an authlo...

Determining current_user with declarative_authorization and authlogic

I use authlogic to authenticate users. In my controllers I use current_user, defined (as documented) as follows: def current_user_session return @current_user_session if defined?(@current_user_session) @current_user_session = UserSession.find end def current_user return @current_user if defined?(@current_user) @cur...

Authlogic: failed_login_count not updating

I'm using Authlogic as the login system. Everything is working correctly except that it never updates the failed_login_count field when I purposely type in the wrong password. I am using the email as the login item. In the database there is no 'login' column. Is there something that I need to change or add to make this feature work? ...

caching with memcached

I have a section in my main layout like the following. I am starting to use memcached and wondering if this portion can be cached somehow becasue the current_user call makes a hit to the database for every page load and by nature of the plugin (authlogic) thats behind it, it actually updates the user record (i.e. the perishable token). ...

Does fetching current_user require a corresponding view?

In my controller i have an action which does not have a corresponding view. Precisely: the upload action for uploading images. However, i require the current users id to store the image url. But the current_user method always returns nil, as the action by itself does not have a view. In such scenarios how do i fetch the current_user? I a...

using fancybox with authlogic

how do I use fancybox with authlogic? I want to use fancybox for doing a login... loading the login form generated by authlogic I found this http://net.tutsplus.com/tutorials/ruby/how-to-build-an-unobtrusive-login-system-in-rails/ but fancybox works differently. Any help? ...

Facebooker with Authlogic is Not Redirecting to the Dashboard After Authorization

Hi. Everything seems to be working fine with my implementation of Facebooker with Authlogic (using the authlogic_facebook_connect plugin) except for one thing. After the initial authorization of the application (by clicking OK on the Facebook pop-up) I still remain on the login page. There is no redirection. However, once I refresh the...

Authlogic with facebook connect

I have successfully integrated facebook connect in my rails app with authlogic. The problem is that if try to update the profile details of the facebook user there is a validation error that the password field cannot be blank. To solve the above issue, I added following to the User model. before_validation :update_authlogic_config ...

Better to hack restful authentication or swap out to something newer like AuthLogin or Warden/Devise?

I've got a rails app with a functioning restful_authentication system but I need to add password reset (never got around to it before...). Also I'm going to be probably adding things like invitations and some features that don't require login. And to be honest I was never completely happen with the way that restful authentication invaded...

Authlogic, multiple user types and multiple relations between the same models

Good morning, I'm trying to figure out the best way to manage this user situation I've got. I have users and affiliates. There is already a HABTM relationship between the two of them, because users can sign up for affiliates, and affiliates can reach out and touch users, in order to get various data points. Now I need to set up a new...

configure authlogic to log in with "username" OR "email"

I implemented authlogic for my authentication system. I was hoping if there was a method to log in users by "username" OR "email" . The solution provided here http://goo.gl/Ato1 doesn't work as I don't have a "login" field in the database. So is it that, I am missing the "login" field in the db? OR is there any other way of handling it?...

no password_confirmation on create but need it during update (authlogic)

I am quite new to rails and I am using authlogic for my authentication system. I want to have password_confirmation when user updates his profile, but not when he is signing up. I figured out this config option acts_as_authentic do |c| c.require_password_confirmation=false end When I do this, it ignores password_confirmation during...

Facebooker with authlogic, problem with script/generate xd_receiver

Hi, I'm trying to follow the tutorial at http://github.com/kalasjocke/authlogic_facebook_connect#readme and getting stuck at the $ script/generate xd_receiver line. It gives an error: Couldn't find 'xd_receiver' generator I read up on similar issues, which said to install the typhoeus gem. I did that and I also made sure that my fac...

Updating user field with current_user when saving nested objects

I'm saving nested objects within the objects they belong to, but when i do that they do not use the controller im saving but the parents controller. class Project < ActiveRecord::Base belongs_to :company belongs_to :user has_many :tasks accepts_nested_attributes_for :tasks, :allow_destroy => true end in the views i have somet...

Collection_Select Default Value Not Set

I am having a strange issue with a collection_select I am using in an edit profile view in my rails application. The database IS being updated with the correct value, however the default value is not being selected for the select box when the user goes to edit their profile. I can not get a :include_blank => true or a :prompt => true t...

Question for holden on authlogic openid/facebook example

This question is specifically for the user holden, but of course if anyone else can answer that works too.. Using the example at: http://github.com/holden/authlogic_openid_selector_example Is the openid code required to get the facebook connect working or are these parts of the example independent? I'm trying to get the kalasjocke fa...

Rails 3rc and Authlogic 2.1.6 functional testing

In Rails 3 rc testing of my controller I can't login with user from fixtures nor (:email=> '', :password =>''). The session object is created but it's user is empty. Everything done just like in manual. And it was worked in rails 2.3.8. I've tryed to: require 'test_helper' require 'authlogic/test_case' class UsersControllerTest < Act...

Facebooker params empty

I am trying to connect facebooker and authlogic using this http://github.com/kalasjocke/authlogic_facebook_connect I was having problems so began to debug the facebooker gem code. I realized that no params are getting set using the facebook login that have anything to do with facebook. I can push the facebook login button, it brings up ...