| | |
| | | * CDDL HEADER END |
| | | * |
| | | * |
| | | * Copyright 2008 Sun Microsystems, Inc. |
| | | * Copyright 2008-2009 Sun Microsystems, Inc. |
| | | */ |
| | | package org.opends.server.workflowelement.localbackend; |
| | | |
| | |
| | | |
| | | |
| | | |
| | | // The backend in which the bind operation should be processed. |
| | | private Backend backend; |
| | | /** |
| | | * The backend in which the bind operation should be processed. |
| | | */ |
| | | protected Backend backend; |
| | | |
| | | // Indicates whether the bind response should include the first warning for an |
| | | // upcoming password expiration. |
| | | private boolean isFirstWarning; |
| | | /** |
| | | * Indicates whether the bind response should include the first warning |
| | | * for an upcoming password expiration. |
| | | */ |
| | | protected boolean isFirstWarning; |
| | | |
| | | // Indicates whether this bind is using a grace login for the user. |
| | | private boolean isGraceLogin; |
| | | /** |
| | | * Indicates whether this bind is using a grace login for the user. |
| | | */ |
| | | protected boolean isGraceLogin; |
| | | |
| | | // Indicates whether the user must change his/her password before doing |
| | | // anything else. |
| | |
| | | // control in the bind response. |
| | | private boolean returnAuthzID; |
| | | |
| | | // Indicates whether to execute post-operation plugins. |
| | | private boolean executePostOpPlugins; |
| | | /** |
| | | * Indicates whether to execute post-operation plugins. |
| | | */ |
| | | protected boolean executePostOpPlugins; |
| | | |
| | | // The client connection associated with this bind operation. |
| | | private ClientConnection clientConnection; |
| | | |
| | | // The bind DN provided by the client. |
| | | private DN bindDN; |
| | | /** |
| | | * The bind DN provided by the client. |
| | | */ |
| | | protected DN bindDN; |
| | | |
| | | // The lookthrough limit that should be enforced for the user. |
| | | private int lookthroughLimit; |
| | |
| | | // The idle time limit that should be enforced for the user. |
| | | private long idleTimeLimit; |
| | | |
| | | // The password policy that applies to the user. |
| | | private PasswordPolicy policy; |
| | | /** |
| | | * The password policy that applies to the user. |
| | | */ |
| | | protected PasswordPolicy policy; |
| | | |
| | | // The password policy state for the user. |
| | | private PasswordPolicyState pwPolicyState; |
| | | /** |
| | | * The password policy state for the user. |
| | | */ |
| | | protected PasswordPolicyState pwPolicyState; |
| | | |
| | | // The password policy error type for this bind operation. |
| | | private PasswordPolicyErrorType pwPolicyErrorType; |
| | |
| | | // The password policy warning type for this bind operation. |
| | | private PasswordPolicyWarningType pwPolicyWarningType; |
| | | |
| | | // The plugin config manager for the Directory Server. |
| | | private PluginConfigManager pluginConfigManager; |
| | | /** |
| | | * The plugin config manager for the Directory Server. |
| | | */ |
| | | protected PluginConfigManager pluginConfigManager; |
| | | |
| | | // The SASL mechanism used for this bind operation. |
| | | private String saslMechanism; |
| | |
| | | * The local backend work-flow element. |
| | | * |
| | | */ |
| | | void processLocalBind(LocalBackendWorkflowElement wfe) |
| | | public void processLocalBind(LocalBackendWorkflowElement wfe) |
| | | { |
| | | this.backend = wfe.getBackend(); |
| | | |
| | |
| | | * @throws DirectoryException If a problem occurs that should cause the bind |
| | | * operation to fail. |
| | | */ |
| | | private boolean processSimpleBind() |
| | | protected boolean processSimpleBind() |
| | | throws DirectoryException |
| | | { |
| | | // See if this is an anonymous bind. If so, then determine whether |
| | |
| | | /** |
| | | * Performs the processing necessary for an anonymous simple bind. |
| | | * |
| | | * @return {@code true} if processing should continue for the operation, or |
| | | * {@code false} if not. |
| | | * @throws DirectoryException If a problem occurs that should cause the bind |
| | | * operation to fail. |
| | | */ |
| | | private boolean processAnonymousSimpleBind() |
| | | protected boolean processAnonymousSimpleBind() |
| | | throws DirectoryException |
| | | { |
| | | // If the server is in lockdown mode, then fail. |
| | |
| | | * @throws DirectoryException If a problem occurs that should cause the bind |
| | | * to fail. |
| | | */ |
| | | private void checkPasswordPolicyState(Entry userEntry, |
| | | SASLMechanismHandler<?> saslHandler) |
| | | protected void checkPasswordPolicyState(Entry userEntry, |
| | | SASLMechanismHandler<?> saslHandler) |
| | | throws DirectoryException |
| | | { |
| | | boolean isSASLBind = (saslHandler != null); |
| | |
| | | * |
| | | * @param userEntry The entry for the authenticated user. |
| | | */ |
| | | private void setResourceLimits(Entry userEntry) |
| | | protected void setResourceLimits(Entry userEntry) |
| | | { |
| | | // See if the user's entry contains a custom size limit. |
| | | AttributeType attrType = |