Uploaded image for project: 'CAS Server'
  1. CAS-1385

LPPE fails with lppe.dateAttribute = null

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.5.2
    • Fix Version/s: 4.0, 4.0 RC3
    • Component/s: LPPE
    • Labels:
      None

      Description

      Hello,

      I wanted to use LPPE module, with cas 3.5.2 and found out that it fails with NullPointerException.
      After debugging I found several users in LDAP who didn't change their password after ppolicy module was enabled. For such users LDAP returns null for pwdChangedTime attribute

      Here is a stacktrace

      SEVERE: Servlet.service() for servlet cas threw exception
      java.lang.NullPointerException at org.joda.time.format.DateTimeFormatterBuilder$NumberFormatter.parseInto(DateTimeFormatterBuilder.java:1292)
      at org.joda.time.format.DateTimeFormatterBuilder$Composite.parseInto(DateTimeFormatterBuilder.java:2695)
      at org.joda.time.format.DateTimeFormatter.parseDateTime(DateTimeFormatter.java:846)
      at org.joda.time.DateTime.parse(DateTime.java:144)
      at org.jasig.cas.adaptors.ldap.LdapPasswordPolicyEnforcer.formatDateByPattern(LdapPasswordPolicyEnforcer.java:394)
      at org.jasig.cas.adaptors.ldap.LdapPasswordPolicyEnforcer.getExpirationDateToUse(LdapPasswordPolicyEnforcer.java:408)
      at org.jasig.cas.adaptors.ldap.LdapPasswordPolicyEnforcer.getNumberOfDaysToPasswordExpirationDate(LdapPasswordPolicyEnforcer.java:225)
      at org.jasig.cas.web.flow.PasswordPolicyEnforcementAction.doExecute(PasswordPolicyEnforcementAction.java:120)
      at org.springframework.webflow.action.AbstractAction.execute(AbstractAction.java:188)
      at org.springframework.webflow.execution.ActionExecutor.execute(ActionExecutor.java:51)
      at org.springframework.webflow.action.EvaluateAction.doExecute(EvaluateAction.java:77)
      at org.springframework.webflow.action.AbstractAction.execute(AbstractAction.java:188)
      at org.springframework.webflow.execution.AnnotatedAction.execute(AnnotatedAction.java:145)
      at org.springframework.webflow.execution.ActionExecutor.execute(ActionExecutor.java:51)
      at org.springframework.webflow.engine.ActionState.doEnter(ActionState.java:101)

        Attachments

          Activity

            People

            • Assignee:
              mmoayyed Misagh Moayyed
              Reporter:
              denis.baklikov Denis Baklikov
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: