org.riotfamily.riot.security.auth
Class UserDaoAuthenticationService

java.lang.Object
  extended by org.riotfamily.riot.security.auth.UserDaoAuthenticationService
All Implemented Interfaces:
AuthenticationService, UserLookupAuthenticationService

public class UserDaoAuthenticationService
extends Object
implements UserLookupAuthenticationService

AuthenticationService that uses a RiotUserDao to lookup a RiotUser.

Since:
6.5
Author:
Felix Gnass [fgnass at neteye dot de]

Constructor Summary
UserDaoAuthenticationService()
           
 
Method Summary
 RiotUser authenticate(String username, String password)
           
 RiotUser getUserById(String userId)
           
 void setUserDao(RiotUserDao userDao)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UserDaoAuthenticationService

public UserDaoAuthenticationService()
Method Detail

setUserDao

public void setUserDao(RiotUserDao userDao)

authenticate

@Transactional
public RiotUser authenticate(String username,
                                           String password)
Specified by:
authenticate in interface AuthenticationService
Parameters:
username - The username
password - The password (plaintext)
Returns:
The RiotUser or null if the user could not be authenticated

getUserById

@Transactional
public RiotUser getUserById(String userId)
Specified by:
getUserById in interface UserLookupAuthenticationService