Uploaded image for project: 'Directory Client API'
  1. Directory Client API
  2. DIRAPI-268

Exception trying to use LDAP Password Modify Extended Operation on samba4 (AWS Simple AD)

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 1.0.0-M33
    • None
    • None
    • Mac OS X

    Description

      Trying to use the LDAP Password Modify Extended Operation with a code like this:

      LdapNetworkConnection connectionForChange = getConnection();
      connectionForChange.bind(userBeingChangedDN, user.getPassword());
      StandaloneLdapApiService codecService = (StandaloneLdapApiService) connectionForChange.getCodecService();
      PasswordModifyFactory prf = (PasswordModifyFactory) codecService.getExtendedOperationsFactories().get("1.3.6.1.4.1.4203.1.11.1");
      PasswordModifyRequest req = prf.newRequest(null);
      req.setNewPassword(newPassword.getBytes("UTF-16LE"));
      req.setOldPassword(user.getPassword().getBytes("UTF-16LE"));
      connectionForChange.extended(req);

      Got this exception:

      WARN [org.apache.directory.ldap.client.api.LdapNetworkConnection:1898] 19/02/2016 17:01:43 -
      java.lang.NullPointerException
      at org.apache.directory.ldap.client.api.LdapNetworkConnection.isNoticeOfDisconnect(LdapNetworkConnection.java:1928)
      at org.apache.directory.ldap.client.api.LdapNetworkConnection.messageReceived(LdapNetworkConnection.java:1958)
      at org.apache.mina.core.filterchain.DefaultIoFilterChain$TailFilter.messageReceived(DefaultIoFilterChain.java:854)
      at org.apache.mina.core.filterchain.DefaultIoFilterChain.callNextMessageReceived(DefaultIoFilterChain.java:542)
      at org.apache.mina.core.filterchain.DefaultIoFilterChain.access$1300(DefaultIoFilterChain.java:48)
      at org.apache.mina.core.filterchain.DefaultIoFilterChain$EntryImpl$1.messageReceived(DefaultIoFilterChain.java:943)
      at org.apache.mina.filter.codec.ProtocolCodecFilter$ProtocolDecoderOutputImpl.flush(ProtocolCodecFilter.java:401)
      at org.apache.mina.filter.codec.ProtocolCodecFilter.messageReceived(ProtocolCodecFilter.java:233)
      at org.apache.mina.core.filterchain.DefaultIoFilterChain.callNextMessageReceived(DefaultIoFilterChain.java:542)
      at org.apache.mina.core.filterchain.DefaultIoFilterChain.access$1300(DefaultIoFilterChain.java:48)
      at org.apache.mina.core.filterchain.DefaultIoFilterChain$EntryImpl$1.messageReceived(DefaultIoFilterChain.java:943)
      at org.apache.mina.core.filterchain.IoFilterAdapter.messageReceived(IoFilterAdapter.java:109)
      at org.apache.mina.core.filterchain.DefaultIoFilterChain.callNextMessageReceived(DefaultIoFilterChain.java:542)
      at org.apache.mina.core.filterchain.DefaultIoFilterChain.fireMessageReceived(DefaultIoFilterChain.java:535)
      at org.apache.mina.core.polling.AbstractPollingIoProcessor.read(AbstractPollingIoProcessor.java:718)
      at org.apache.mina.core.polling.AbstractPollingIoProcessor.process(AbstractPollingIoProcessor.java:672)
      at org.apache.mina.core.polling.AbstractPollingIoProcessor.process(AbstractPollingIoProcessor.java:661)
      at org.apache.mina.core.polling.AbstractPollingIoProcessor.access$600(AbstractPollingIoProcessor.java:68)
      at org.apache.mina.core.polling.AbstractPollingIoProcessor$Processor.run(AbstractPollingIoProcessor.java:1130)
      at org.apache.mina.util.NamePreservingRunnable.run(NamePreservingRunnable.java:64)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      at java.lang.Thread.run(Thread.java:745)

      Attachments

        Activity

          People

            Unassigned Unassigned
            brunojcm Bruno Medeiros
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: