mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Jean-Noel Rouvignac
16.57.2015 a41662c1136b2bb4a4198df89e0e87d2be3ef099
opendj-server-legacy/src/main/java/org/opends/server/tasks/LeaveLockdownModeTask.java
@@ -64,16 +64,15 @@
    if (operation != null)
    {
      DN authzDN = operation.getAuthorizationDN();
      if ((authzDN == null) || (! operation.getClientConnection().hasPrivilege(
          Privilege.SERVER_LOCKDOWN, operation)))
      if (authzDN == null || !operation.getClientConnection().hasPrivilege(
          Privilege.SERVER_LOCKDOWN, operation))
      {
        LocalizableMessage message = ERR_TASK_LEAVELOCKDOWN_NOT_ROOT.get();
        throw new DirectoryException(ResultCode.UNWILLING_TO_PERFORM, message);
      }
      InetAddress clientAddress =
           operation.getClientConnection().getRemoteAddress();
      if ((clientAddress != null) && (! clientAddress.isLoopbackAddress()))
      InetAddress clientAddress = operation.getClientConnection().getRemoteAddress();
      if (clientAddress != null && !clientAddress.isLoopbackAddress())
      {
        LocalizableMessage message = ERR_TASK_LEAVELOCKDOWN_NOT_LOOPBACK.get();
        throw new DirectoryException(ResultCode.UNWILLING_TO_PERFORM, message);
@@ -90,4 +89,3 @@
    return TaskState.COMPLETED_SUCCESSFULLY;
  }
}