Uploaded image for project: 'DSpace'
  1. DSpace
  2. DS-3428

LDAP Authentication doesn't work if log level is DEBUG

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: More Details Needed (View Workflow)
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 6.0
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Environment:
      Windows 7
      PostGreSQL 9.5
    • Attachments:
      0
    • Comments:
      2
    • Documentation Status:
      Needed

      Description

      If log level is DEBUG (log4j.properties : loglevel.dspace=DEBUG), there is an error when trying to authenticate with LDAP) : message on the web page :
      Java stacktrace:
      java.util.EmptyStackException at java.util.Stack.peek(Stack.java:102) at java.util.Stack.pop(Stack.java:84) at org.dspace.core.Context.restoreAuthSystemState(Context.java:287)
      ...
      In dspace.log : the authentication with LDAP is OK but there is a problem with creating or updating the EPerson : a warning and it stops
      2016-12-19 16:57:17,777 INFO org.dspace.authenticate.LDAPAuthentication @ anonymous:session_id=:auth:attempting trivial auth of user=b
      2016-12-19 16:57:17,964 DEBUG org.dspace.authenticate.LDAPAuthentication @ anonymous:session_id=F*:got DN:uid=B*,ou=,o=,c=*
      2016-12-19 16:57:18,011 INFO org.dspace.authenticate.LDAPAuthentication @ anonymous:session_id=F*:autoregister:netid=b*
      2016-12-19 16:57:18,011 INFO org.dspace.authenticate.LDAPAuthentication @ anonymous:session_id=F:type=ldap-login:type=ldap_but_already_email
      2016-12-19 16:57:18,011 INFO org.dspace.eperson.EPersonServiceImpl @ anonymous:session_id=F:update_eperson:eperson_id=b08*
      2016-12-19 16:57:18,136 WARN org.dspace.core.Context @ @.:session_id=F:restore_auth_sys_state:not previous state info available null

      I switch log level to INFO in log4j.properties and no more error on the web page.
      There is still the same warning "restore_auth_sys_state:not previous state info available null" in dspace.log but it goes on and the EPerson is created or updated.
      The problem may be related to the special treatment for log level DEBUG in org.dspace.core.Context (turnOffAuthorisationSystem(), restoreAuthSystemState())?

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              devaux Cedric Devaux
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: