I could use a bit of help straightening out my Auth, Autth->login. In the
process of trying to get it to work I made a nice enough mess that I just
need to start over.
I'm not using Form based Authentication (first time I've attempted this)
and I'm also using a Model other than User (first time also).
I've tried lots of variations but as of right now my AppController
beforeFilter() contains:
$this->Auth->authenticate = array(AuthComponent::ALL => array('userModel'
=> 'Developer'),'Basic');
$this->Auth->userScope = array('Developer.id' =>
$this->facebook->getUser());
My Developer->login() contains:
$user['Developer']['id'] = $this->facebook->getUser();
if($this->Auth->login($user)){
// login successful
} else {
// login failed
}
I've ensured that $this->facebook->getUser() must be set to access the
login() method.
My Developer Model is empty, Zero records.
When I initiate the login() it succeeds every time even though it should
most definitely be failing.
Another issue is that non-logged-in users are able access methods that are
not contained within $this->Auth->allowedActions.
If I'm not using the User Model would I still access the user through
$this->Auth->user(), or would I have to change it up a bit?
$this->Auth->user('Developer.id')?
As always, any and all help is greatly appreciated.
--
Our newest site for the community: CakePHP Video Tutorials
http://tv.cakephp.org
Check out the new CakePHP Questions site http://ask.cakephp.org and help others
with their CakePHP related questions.
To unsubscribe from this group, send email to
[email protected] For more options, visit this group at
http://groups.google.com/group/cake-php