System.out.println("Using configured PlainTextPasswordValidator................");
PasswordValidationCallback.PlainTextPasswordRequest plainTextRequest =
(PasswordValidationCallback.PlainTextPasswordRequest) request;
if ("alice".equals(plainTextRequest.getUsername()) &&
"alice".equals(plainTextRequest.getPassword())) {
return true;
}else if ("bob".equals(plainTextRequest.getUsername()) &&
"bob".equals(plainTextRequest.getPassword())) {
return true;
}
return false;