Search in sources :

Example 16 with PwPolicy

use of org.apache.directory.fortress.core.model.PwPolicy in project directory-fortress-core by apache.

the class PwPolicyMgrImpl method read.

/**
 * {@inheritDoc}
 */
@Override
@AdminPermissionOperation
public PwPolicy read(String name) throws SecurityException {
    String methodName = "read";
    VUtil.assertNotNullOrEmpty(name, GlobalErrIds.PSWD_NAME_NULL, CLS_NM + "." + methodName);
    checkAccess(CLS_NM, methodName);
    PwPolicy policy = new PwPolicy(name);
    policy.setContextId(this.contextId);
    return policyP.read(policy);
}
Also used : PwPolicy(org.apache.directory.fortress.core.model.PwPolicy) AdminPermissionOperation(org.apache.directory.fortress.annotation.AdminPermissionOperation)

Example 17 with PwPolicy

use of org.apache.directory.fortress.core.model.PwPolicy in project directory-fortress-core by apache.

the class PwPolicyMgrImpl method search.

/**
 * {@inheritDoc}
 */
@Override
@AdminPermissionOperation
public List<PwPolicy> search(String searchVal) throws SecurityException {
    String methodName = "search";
    VUtil.assertNotNull(searchVal, GlobalErrIds.PSWD_NAME_NULL, CLS_NM + "." + methodName);
    checkAccess(CLS_NM, methodName);
    PwPolicy policy = new PwPolicy(searchVal);
    policy.setContextId(this.contextId);
    return policyP.search(policy);
}
Also used : PwPolicy(org.apache.directory.fortress.core.model.PwPolicy) AdminPermissionOperation(org.apache.directory.fortress.annotation.AdminPermissionOperation)

Aggregations

PwPolicy (org.apache.directory.fortress.core.model.PwPolicy)17 SecurityException (org.apache.directory.fortress.core.SecurityException)9 PwPolicyMgr (org.apache.directory.fortress.core.PwPolicyMgr)6 FortRequest (org.apache.directory.fortress.core.model.FortRequest)3 FortResponse (org.apache.directory.fortress.core.model.FortResponse)3 LdapException (org.apache.directory.api.ldap.model.exception.LdapException)2 AdminPermissionOperation (org.apache.directory.fortress.annotation.AdminPermissionOperation)2 FinderException (org.apache.directory.fortress.core.FinderException)2 LdapConnection (org.apache.directory.ldap.client.api.LdapConnection)2 ArrayList (java.util.ArrayList)1 CursorException (org.apache.directory.api.ldap.model.cursor.CursorException)1 SearchCursor (org.apache.directory.api.ldap.model.cursor.SearchCursor)1 DefaultEntry (org.apache.directory.api.ldap.model.entry.DefaultEntry)1 Entry (org.apache.directory.api.ldap.model.entry.Entry)1 LdapNoSuchObjectException (org.apache.directory.api.ldap.model.exception.LdapNoSuchObjectException)1 ValidationException (org.apache.directory.fortress.core.ValidationException)1 AdminRole (org.apache.directory.fortress.core.model.AdminRole)1 ObjectFactory (org.apache.directory.fortress.core.model.ObjectFactory)1 OrgUnit (org.apache.directory.fortress.core.model.OrgUnit)1 Role (org.apache.directory.fortress.core.model.Role)1