Examples of lookupAttributeTypeRegistry()


Examples of org.apache.directory.shared.ldap.model.schema.SchemaManager.lookupAttributeTypeRegistry()

        assertTrue( isATPresent( schemaManager, "1.1.1.0" ) );

        assertEquals( atrSize + 1, schemaManager.getAttributeTypeRegistry().size() );
        assertEquals( goidSize + 1, schemaManager.getGlobalOidRegistry().size() );

        AttributeType added = schemaManager.lookupAttributeTypeRegistry( "referral" );
        assertNotNull( added );
        assertEquals( "1.1.1.0", added.getOid() );
        assertTrue( added.getNames().contains( "referral" ) );
    }
View Full Code Here

Examples of org.apache.directory.shared.ldap.model.schema.SchemaManager.lookupAttributeTypeRegistry()

        attributeType.setUsage( UsageEnum.DIRECTORY_OPERATION );

        // It should not fail
        assertTrue( schemaManager.add( attributeType ) );

        AttributeType result = schemaManager.lookupAttributeTypeRegistry( "1.1.0" );

        assertEquals( "1.3.6.1.4.1.1466.115.121.1.12", result.getSyntaxOid() );
        assertEquals( "2.5.13.1", result.getEqualityOid() );
        assertEquals( atrSize + 1, schemaManager.getAttributeTypeRegistry().size() );
        assertEquals( goidSize + 1, schemaManager.getGlobalOidRegistry().size() );
View Full Code Here

Examples of org.apache.directory.shared.ldap.model.schema.SchemaManager.lookupAttributeTypeRegistry()

        // Find the OID for this index
        SchemaManager schemaManager = directoryService.getSchemaManager();
       
        try
        {
            AttributeType indexAT = schemaManager.lookupAttributeTypeRegistry( indexFileName );
            indexFileName = indexAT.getOid();
        }
        catch ( LdapException le )
        {
            // Not found ? We will use the index file name
View Full Code Here

Examples of org.apache.directory.shared.ldap.model.schema.SchemaManager.lookupAttributeTypeRegistry()

        }

        SchemaManager schemaManager = session.getDirectoryService().getSchemaManager();
       
        Attribute newPasswordAttribute = new DefaultAttribute(
            schemaManager.lookupAttributeTypeRegistry( SchemaConstants.USER_PASSWORD_AT ), Strings.getBytesUtf8(newPassword) );
        Modification passwordMod = new DefaultModification( ModificationOperation.REPLACE_ATTRIBUTE, newPasswordAttribute );
       
        Attribute principalAttribute = new DefaultAttribute(
            schemaManager.lookupAttributeTypeRegistry( KerberosAttribute.KRB5_PRINCIPAL_NAME_AT ), principal.getName() );
        Modification principalMod = new DefaultModification( ModificationOperation.REPLACE_ATTRIBUTE, principalAttribute );
View Full Code Here

Examples of org.apache.directory.shared.ldap.model.schema.SchemaManager.lookupAttributeTypeRegistry()

        Attribute newPasswordAttribute = new DefaultAttribute(
            schemaManager.lookupAttributeTypeRegistry( SchemaConstants.USER_PASSWORD_AT ), Strings.getBytesUtf8(newPassword) );
        Modification passwordMod = new DefaultModification( ModificationOperation.REPLACE_ATTRIBUTE, newPasswordAttribute );
       
        Attribute principalAttribute = new DefaultAttribute(
            schemaManager.lookupAttributeTypeRegistry( KerberosAttribute.KRB5_PRINCIPAL_NAME_AT ), principal.getName() );
        Modification principalMod = new DefaultModification( ModificationOperation.REPLACE_ATTRIBUTE, principalAttribute );
       
        //FIXME check if keyderivation is necessary
       
        Entry entry = StoreUtils.findPrincipalEntry( session, searchBaseDn, principal.getName() );
View Full Code Here

Examples of org.apache.directory.shared.ldap.model.schema.SchemaManager.lookupAttributeTypeRegistry()

                {
                    SchemaManager schemaManager = ldapServer.getDirectoryService().getSchemaManager();
   
                    try
                    {
                        AttributeType type = schemaManager.lookupAttributeTypeRegistry( id );
                        return !type.getSyntax().isHumanReadable();
                    }
                    catch ( Exception e )
                    {
                        return !Strings.isEmpty(id) && id.endsWith(";binary");
View Full Code Here

Examples of org.apache.directory.shared.ldap.model.schema.SchemaManager.lookupAttributeTypeRegistry()

        }

        SchemaManager schemaManager = session.getDirectoryService().getSchemaManager();

        Attribute newPasswordAttribute = new DefaultAttribute(
            schemaManager.lookupAttributeTypeRegistry( SchemaConstants.USER_PASSWORD_AT ),
            Strings.getBytesUtf8( newPassword ) );
        Modification passwordMod = new DefaultModification( ModificationOperation.REPLACE_ATTRIBUTE,
            newPasswordAttribute );

        Attribute principalAttribute = new DefaultAttribute(
View Full Code Here

Examples of org.apache.directory.shared.ldap.model.schema.SchemaManager.lookupAttributeTypeRegistry()

            Strings.getBytesUtf8( newPassword ) );
        Modification passwordMod = new DefaultModification( ModificationOperation.REPLACE_ATTRIBUTE,
            newPasswordAttribute );

        Attribute principalAttribute = new DefaultAttribute(
            schemaManager.lookupAttributeTypeRegistry( KerberosAttribute.KRB5_PRINCIPAL_NAME_AT ), principal.getName() );
        Modification principalMod = new DefaultModification( ModificationOperation.REPLACE_ATTRIBUTE,
            principalAttribute );

        //FIXME check if keyderivation is necessary
View Full Code Here

Examples of org.apache.directory.shared.ldap.schema.SchemaManager.lookupAttributeTypeRegistry()

            {
                SchemaManager schemaManager = directoryService.getSchemaManager();
               
                try
                {
                    AttributeType type = schemaManager.lookupAttributeTypeRegistry( id );
                    return ! type.getSyntax().isHumanReadable();
                }
                catch ( Exception e )
                {
                    if ( StringTools.isEmpty( id ) )
View Full Code Here

Examples of org.apache.directory.shared.ldap.schema.SchemaManager.lookupAttributeTypeRegistry()

        SchemaManager schemaManager = session.getDirectoryService().getSchemaManager();
       
        List<Modification> mods = new ArrayList<Modification>(2);
       
        ServerAttribute newPasswordAttribute = new DefaultServerAttribute(
            schemaManager.lookupAttributeTypeRegistry( SchemaConstants.USER_PASSWORD_AT ), StringTools.getBytesUtf8( newPassword ) );
        mods.add( new ServerModification( ModificationOperation.REPLACE_ATTRIBUTE, newPasswordAttribute ) );
       
        ServerAttribute principalAttribute = new DefaultServerAttribute(
            schemaManager.lookupAttributeTypeRegistry( KerberosAttribute.KRB5_PRINCIPAL_NAME_AT ), principal.getName() );
        mods.add( new ServerModification( ModificationOperation.REPLACE_ATTRIBUTE, principalAttribute ) );
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.