Possible Duplicate:
Automatic post-registration user authentication
I made an authentication using my database users and using my own form. The password is encrypted using md5. It worked PERFECTLY.
What i need is authenticate a user by my code on a controller or elsewhere... something like that:
$x = $this->get('security.context');
$x->getToken()->setUser($user)->authenticate();
If you see, the setUser exists, but i need a really authenticate method.
Thanks