Page 3 of 4
1 · 2 · 3 · 4

lecterror :: 03.02.2009 03:06:08
Hi bearking,

I'm not very proficient with Japanese, but I don't understand how is that component safer than this one? I can still be automatically logged in when I have your cookie, no matter how it's written or what's in it.

In terms of reverse-engineering the password, I assume the other component is safer, but I just don't see why would anyone waste any time on that. If I want to log in, I already have the cookie, I don't need the password.

But please do correct me if I'm wrong.
JohnnyBeton :: 03.02.2009 16:48:02
My first page is a static page, which is ignored by AuthComponent ($this->Auth->allow('display')). Because of enabling and disabling parts of my menu-element, I also want to login via the cookie at this moment and not only, when an action is called, which is behind the AuthComponent.

Do you have any idea to solve this problem?

Thanks!
lecterror :: 07.02.2009 09:12:13
Hi JohnnyBeton,

although your public functions are ignored by the Auth, the beforeFilter() callback is always called regardless of Auth. This component should work in all cases (at least it does for me).

Or did I misinterpret your question?
adam :: 22.04.2009 11:24:28
alex:
are you calling parent::beforeFilter(); within the UsersController's beforeFilter? if you don't, it will only execute the UsersController's beforeFilter, and not both.
senseBOP :: 15.05.2009 06:06:41
Hey, great piece of code!

Perhaps you should use a custom variable to access the Auth component to make the component more generic and easy to extend/use. For example, one might be using an extension of the Auth component called 'SuperiorAuth'. Using a custom variable to tell the RememberMe component what Auth component it should use will easily let users implement this component into their existing code environment.

So, instead of this:
$this->Auth->call_method();

You would have this:

var $authComponent = 'SuperiorAuth';
$this->{$this->authComponent}->call_method();

Which could then also be set from the AppController, like so:
$this->RememberMe->authComponent= 'SuperiorAuth';

What say you?