package org.xdi.oxauth.model.configuration;

/**
 * Brute Force authentication configuration
 *
 * @author Yuriy Movchan Date: 08/22/2018
 */
public class AuthenticationProtectionConfiguration {

    private int attemptExpiration;
    private int maximumAllowedAttempts;
    private int maximumAllowedAttemptsWithoutDelay;

    private int delayTime;
    
    private Boolean bruteForceProtectionEnabled;

    public final int getAttemptExpiration() {
        return attemptExpiration;
    }

    public final void setAttemptExpiration(int attemptExpiration) {
        this.attemptExpiration = attemptExpiration;
    }

    public final int getMaximumAllowedAttempts() {
        return maximumAllowedAttempts;
    }

    public final void setMaximumAllowedAttempts(int maximumAllowedAttempts) {
        this.maximumAllowedAttempts = maximumAllowedAttempts;
    }

    public final int getMaximumAllowedAttemptsWithoutDelay() {
        return maximumAllowedAttemptsWithoutDelay;
    }

    public final void setMaximumAllowedAttemptsWithoutDelay(int maximumAllowedAttemptsWithoutDelay) {
        this.maximumAllowedAttemptsWithoutDelay = maximumAllowedAttemptsWithoutDelay;
    }

    public final int getDelayTime() {
        return delayTime;
    }

    public final void setDelayTime(int delayTime) {
        this.delayTime = delayTime;
    }

    public final Boolean getBruteForceProtectionEnabled() {
        return bruteForceProtectionEnabled;
    }

    public final void setBruteForceProtectionEnabled(Boolean bruteForceProtectionEnabled) {
        this.bruteForceProtectionEnabled = bruteForceProtectionEnabled;
    }

}

@@ -40,16 +40,73 @@
 ion;
-%0D%0A%0D
+%0A%0Aimport org.codehaus.jackson.annotate.JsonIgnoreProperties;%0A
 %0A/**
-%0D
 %0A * 
@@ -149,13 +149,11 @@
 tion
-%0D
 %0A *
-%0D
 %0A * 
@@ -194,14 +194,56 @@
 2018
-%0D
 %0A */
-%0D
+%0A@JsonIgnoreProperties(ignoreUnknown = true)
 %0Apub
@@ -291,19 +291,17 @@
 ration %7B
-%0D%0A%0D
+%0A
 %0A    pri
@@ -331,50 +331,8 @@
 ion;
-%0D%0A    private int maximumAllowedAttempts;%0D
 %0A   
@@ -379,19 +379,17 @@
 utDelay;
-%0D%0A%0D
+%0A
 %0A    pri
@@ -411,15 +411,13 @@
 ime;
-%0D
 %0A    
-%0D
 %0A   
@@ -461,19 +461,17 @@
 Enabled;
-%0D%0A%0D
+%0A
 %0A    pub
@@ -504,25 +504,24 @@
 piration() %7B
-%0D
 %0A        ret
@@ -538,34 +538,31 @@
 tExpiration;
-%0D
 %0A    %7D
-%0D%0A%0D
+%0A
 %0A    public 
@@ -617,17 +617,16 @@
 ation) %7B
-%0D
 %0A       
@@ -673,270 +673,15 @@
 ion;
-%0D
 %0A    %7D
-%0D%0A%0D%0A    public final int getMaximumAllowedAttempts() %7B%0D%0A        return maximumAllowedAttempts;%0D%0A    %7D%0D%0A%0D%0A    public final void setMaximumAllowedAttempts(int maximumAllowedAttempts) %7B%0D%0A        this.maximumAllowedAttempts = maximumAllowedAttempts;%0D%0A    %7D%0D%0A%0D
+%0A
 %0A   
@@ -735,25 +735,24 @@
 outDelay() %7B
-%0D
 %0A        ret
@@ -786,34 +786,31 @@
 ithoutDelay;
-%0D
 %0A    %7D
-%0D%0A%0D
+%0A
 %0A    public 
@@ -899,17 +899,16 @@
 Delay) %7B
-%0D
 %0A       
@@ -985,26 +985,23 @@
 utDelay;
-%0D
 %0A    %7D
-%0D%0A%0D
+%0A
 %0A    pub
@@ -1026,25 +1026,24 @@
 elayTime() %7B
-%0D
 %0A        ret
@@ -1052,34 +1052,31 @@
 n delayTime;
-%0D
 %0A    %7D
-%0D%0A%0D
+%0A
 %0A    public 
@@ -1115,17 +1115,16 @@
 yTime) %7B
-%0D
 %0A       
@@ -1151,26 +1151,23 @@
 layTime;
-%0D
 %0A    %7D
-%0D%0A%0D
+%0A
 %0A    pub
@@ -1218,17 +1218,16 @@
 bled() %7B
-%0D
 %0A       
@@ -1262,26 +1262,23 @@
 Enabled;
-%0D
 %0A    %7D
-%0D%0A%0D
+%0A
 %0A    pub
@@ -1361,17 +1361,16 @@
 abled) %7B
-%0D
 %0A       
@@ -1437,18 +1437,14 @@
 led;
-%0D
 %0A    %7D
-%0D%0A%0D
+%0A
 %0A%7D
-%0D
 %0A

Remove unused maximumAllowedAttempts