Package io.jmix.security
Interface BruteForceProtection
- All Known Implementing Classes:
- BruteForceProtectionImpl
public interface BruteForceProtection
Class is responsible for the brute-force protection on user authentication.
- 
Method SummaryModifier and TypeMethodDescriptionbooleanReturns a number of login attempts left for the specified pair of login and IP-address.booleanvoidregisterLoginFailed(String username, String ipAddress) Registers unsuccessful login attempt.voidregisterLoginSucceeded(String username, String ipAddress) Registers successful login attempt.
- 
Method Details- 
isBlockedReturns a number of login attempts left for the specified pair of login and IP-address.- Parameters:
- username- username.
- ipAddress- user IP-address.
- Returns:
- true if count of login attempts left.
 
- 
registerLoginFailedRegisters unsuccessful login attempt.
- 
isProtectionEnabledboolean isProtectionEnabled()- Returns:
- true if brute-force protection is enabled in application settings.
 
- 
registerLoginSucceededRegisters successful login attempt. Clear attempts count for user.- Parameters:
- username- username.
- ipAddress- user IP-address.
 
 
-