if (expiresOn.before(now) && expiryInDays > 0) {
scheme.getServletSession().setAttribute(Constants.PASSWORD_CHANGE_REASON_MESSAGE,
new ActionMessage("passwordChange.expired"));
} else if (warningOn.before(now) && warningInDays > 0) {
long daysToExpiry = ((expiresOn.getTimeInMillis() - now.getTimeInMillis()) + 86399999l) / 86400000l;
GlobalWarningManager.getInstance().addToSession(new GlobalWarning(scheme.getServletSession(), new BundleActionMessage("navigation",
"globalWarning.passwordNearExpiry", new Long(daysToExpiry))));
}
} else if (scheme.getUser().requiresPasswordChange()) {
scheme.getServletSession().setAttribute(Constants.PASSWORD_CHANGE_REASON_MESSAGE,