Interface CredentialService
- All Known Implementing Classes:
CryptoCredential,NoOpCredential,StrongHashCredential
public interface CredentialService
사용자의 password 를 검증하고 설정하는 credential service.
- Version:
- $Id$
- Author:
- Youngho Cho
-
Method Summary
Modifier and TypeMethodDescriptionbooleanauthenticate(User user, String password) Authenticate a user with the specified password.voidsetPassword(User user, String password) Set password for a user.
-
Method Details
-
authenticate
boolean authenticate(User user, String password) throws PasswordMismatchException, UnknownEntityException, DataBackendException Authenticate a user with the specified password. If authentication is successful the method returns true. If it fails, it returns false.- Parameters:
user- a User object.password- the user supplied password. (plain text)- Returns:
- 인증에 성공하면
true - Throws:
PasswordMismatchException- password 를 검증할 수 없는 경우UnknownEntityException- 사용자가 존재하지 않는 경우DataBackendException- 저장소 접근 중 오류가 발생한 경우
-
setPassword
Set password for a user.- Parameters:
user- a User object.password- the new password to be set. (plain text)- Throws:
UnknownEntityException- 사용자가 존재하지 않는 경우DataBackendException- password 변환 또는 저장 중 오류가 발생한 경우
-