appfoundation을 사용하여 실패한 로그인 시도 방법은 무엇입니까? 그것은 getFailedLoginAttempts() 함수를 가지고 있지만 아무 의미가 없습니다. 내가 코멘트에있는 모든 문제를 썼다Vaadin에서 getFailedLoginAttempts() 함수가 의미가 없습니다.
NativeButton login = new NativeButton(Lang.getMessage("login"), new ClickListener() {
private static final long serialVersionUID = -5577423546946890721L;
public void buttonClick(ClickEvent event) {
username = (String) usernameField.getValue();
String password = (String) passwordField.getValue();
try {
AuthenticationUtil.authenticate(username, password);
startApp();
} catch (InvalidCredentialsException e) {
/* I need to get failed login attempts here but how can I do that?
I just can by doing this: AuthenticationUtil.authenticate(username, password).
getFailedLoginAttempts(), but I need to write try and catch blocks
(so try and catch blocks in catch block) for authenticate method and this
function will never work, because user won't be authenticated and all
the time you will go to the other catch block; */
feedbackLabel.setValue(Lang.getMessage("usernameOrPasswordIncorect"));
} catch (AccountLockedException e) {
feedbackLabel.setValue(Lang.getMessage("accountBlocked"));
}
}
});
: 나는
내 코드는 여기에 만약 angel 6 (6.8.12)를 사용하고 있습니다. 실패한 로그인 시도 횟수를 인쇄하려고하지만이 번호를 얻을 수 없습니다. 어떤 제안?
사용중인 버디의 버전 –
@ user2310289 편집 됨. –