org.persvr.security
Interface SecurityHandler

All Known Implementing Classes:
DefaultSecurity

public interface SecurityHandler

This provides an interface for defining how security and authentication is handled.

Author:
Kris Zyp

Method Summary
 User authenticate(java.lang.String username, java.lang.String password)
          This performs authentication and returns the authenticated User
 User createUser(java.lang.String username, java.lang.String password)
          Creates a new user in the system
 User getPublicUser()
          This gets the public user.
 

Method Detail

getPublicUser

User getPublicUser()
This gets the public user. People that connect to the system without a login will be using this user.

Returns:

authenticate

User authenticate(java.lang.String username,
                  java.lang.String password)
                  throws javax.security.auth.login.LoginException
This performs authentication and returns the authenticated User

Parameters:
username -
password -
Returns:
Throws:
javax.security.auth.login.LoginException

createUser

User createUser(java.lang.String username,
                java.lang.String password)
Creates a new user in the system

Parameters:
username -
password -
Returns:
the newly created user