diff --git a/modules/eeuser/src/main/java/org/jpos/ee/User.java b/modules/eeuser/src/main/java/org/jpos/ee/User.java index 43d7e205b5..5a39508fef 100644 --- a/modules/eeuser/src/main/java/org/jpos/ee/User.java +++ b/modules/eeuser/src/main/java/org/jpos/ee/User.java @@ -39,6 +39,10 @@ public class User extends Cloneable implements Serializable, SoftDelete { private Date startDate; private Date endDate; private List passwordhistory; + private boolean forcePasswordChange; + private Date lastLogin; + private Date passwordChanged; + private int loginAttempts; public User() { super(); @@ -104,7 +108,42 @@ public void setPasswordhistory (List passwordhistory) { } public List getPasswordhistory () { return passwordhistory; - } + } + public boolean isForcePasswordChange() { + return forcePasswordChange; + } + + public void setForcePasswordChange(boolean forcePasswordChange) { + this.forcePasswordChange = forcePasswordChange; + } + + public Date getLastLogin() { + return lastLogin; + } + + public void setLastLogin(Date lastLogin) { + this.lastLogin = lastLogin; + } + + public Date getPasswordChanged() { + return passwordChanged; + } + + public void setPasswordChanged(Date passwordChanged) { + this.passwordChanged = passwordChanged; + } + + public int getLoginAttempts() { + return loginAttempts; + } + + public void setLoginAttempts(int loginAttempts) { + this.loginAttempts = loginAttempts; + } + + public void incLoginAttempts () { + this.loginAttempts++; + } public boolean hasPermission (String permName) { if (permName != null) { for (Role r : roles) { diff --git a/modules/eeuser/src/main/resources/org/jpos/ee/User.hbm.xml b/modules/eeuser/src/main/resources/org/jpos/ee/User.hbm.xml index d3706ebbac..a08e4378a5 100644 --- a/modules/eeuser/src/main/resources/org/jpos/ee/User.hbm.xml +++ b/modules/eeuser/src/main/resources/org/jpos/ee/User.hbm.xml @@ -48,6 +48,11 @@ + + + + +