Examples of toJndiEnvironment()


Examples of org.apache.activemq.jaas.ldap.MutableServerStartupConfiguration.toJndiEnvironment()

        startup.setLdapPort(9389);
        startup.setEnableNetworking(true);
        startup.setHost(InetAddress.getByName("localhost"));

        Properties env = new Properties();
        env.putAll(startup.toJndiEnvironment());
        env.put(Context.INITIAL_CONTEXT_FACTORY, ServerContextFactory.class.getName());
        env.put(Context.PROVIDER_URL, "ou=system");
        env.put(Context.SECURITY_AUTHENTICATION, "simple");
        env.put(Context.SECURITY_PRINCIPAL, PRINCIPAL);
        env.put(Context.SECURITY_CREDENTIALS, CREDENTIALS);
View Full Code Here

Examples of org.apache.activemq.jaas.ldap.MutableServerStartupConfiguration.toJndiEnvironment()

        startup.setLdapPort(9389);
        startup.setEnableNetworking(true);
        startup.setHost(InetAddress.getByName("localhost"));

        Properties env = new Properties();
        env.putAll(startup.toJndiEnvironment());
        env.put(Context.INITIAL_CONTEXT_FACTORY, ServerContextFactory.class.getName());
        env.put(Context.PROVIDER_URL, "ou=system");
        env.put(Context.SECURITY_AUTHENTICATION, "simple");
        env.put(Context.SECURITY_PRINCIPAL, PRINCIPAL);
        env.put(Context.SECURITY_CREDENTIALS, CREDENTIALS);
View Full Code Here

Examples of org.apache.directory.server.configuration.MutableServerStartupConfiguration.toJndiEnvironment()

                Set pcfgs = addCustomPartition();
                cfg.setContextPartitionConfigurations( pcfgs );
            }

            // Put the configuration instruction to the environment variable.
            env.putAll( cfg.toJndiEnvironment() );

            new InitialDirContext( env );
        }
        else
        {
View Full Code Here

Examples of org.apache.directory.server.configuration.MutableServerStartupConfiguration.toJndiEnvironment()

            env.setProperty( Context.SECURITY_CREDENTIALS, password );
        }
        env.setProperty( Context.SECURITY_AUTHENTICATION, "simple" );
        env.setProperty( Context.PROVIDER_URL, "ou=system" );
        env.setProperty( Context.INITIAL_CONTEXT_FACTORY, ServerContextFactory.class.getName() );
        env.putAll( configuration.toJndiEnvironment() );
        InitialDirContext context = new InitialDirContext( env );

        //Attributes inetAttributes = context.getAttributes( "cn=inetorgperson,ou=schema" );

        //inetAttributes.remove( "m-disabled" );
View Full Code Here

Examples of org.apache.directory.server.configuration.MutableServerStartupConfiguration.toJndiEnvironment()

        cfg.setContextPartitionConfigurations(Collections
                .singleton(partitionConfiguration));
        // Start the Server
   
        Hashtable<String, String> env = createEnv(principal, credentials);
        env.putAll(cfg.toJndiEnvironment());
        return new InitialDirContext(env);
    }
   
    /**
     * Initializes an in-memory LDAP server to use for testing.
View Full Code Here

Examples of org.apache.directory.server.core.configuration.ShutdownConfiguration.toJndiEnvironment()

            // Build the properties from bean attributes
            Hashtable env = createContextEnv();

            // Put the configuration instruction to the environment variable.
            env.putAll( cfg.toJndiEnvironment() );

            new InitialDirContext( env );
        }
    }
View Full Code Here

Examples of org.apache.directory.server.core.configuration.StartupConfiguration.toJndiEnvironment()

        StartupConfiguration cfg = (StartupConfiguration) factory.getBean("configuration");
        Properties env = (Properties) factory.getBean("environment");

        env.setProperty(Context.PROVIDER_URL, "");
        env.setProperty(Context.INITIAL_CONTEXT_FACTORY, CoreContextFactory.class.getName());
        env.putAll(cfg.toJndiEnvironment());

        new InitialDirContext(env);
    }

    protected void tearDown() throws Exception {
View Full Code Here

Examples of org.apache.directory.server.core.configuration.StartupConfiguration.toJndiEnvironment()

        StartupConfiguration cfg = (StartupConfiguration) factory.getBean("configuration");
        Properties env = (Properties) factory.getBean("environment");

        env.setProperty(Context.PROVIDER_URL, "");
        env.setProperty(Context.INITIAL_CONTEXT_FACTORY, CoreContextFactory.class.getName());
        env.putAll(cfg.toJndiEnvironment());

        new InitialDirContext(env);
    }

    protected void tearDown() throws Exception {
View Full Code Here

Examples of org.apache.directory.server.core.configuration.SyncConfiguration.toJndiEnvironment()

                // Build the properties from bean attributes
                Hashtable env = createContextEnv();

                // Put the configuration instruction to the environment
                // variable.
                env.putAll( cfg.toJndiEnvironment() );

                if ( LOG.isDebugEnabled() )
                {
                    LOG.info( "Directory Properties:" );
View Full Code Here

Examples of org.apache.ldap.server.configuration.MutableStartupConfiguration.toJndiEnvironment()

    public void testDelete() throws NamingException
    {
        MutableStartupConfiguration cfg = new MutableStartupConfiguration();
        cfg.setWorkingDirectory( new File( "target" + File.separator + "server" ) );

        Hashtable env = new Hashtable( cfg.toJndiEnvironment() );
        env.put( Context.PROVIDER_URL, "" );
        env.put( Context.SECURITY_PRINCIPAL, "uid=admin,ou=system" );
        env.put( Context.SECURITY_CREDENTIALS, "secret" );
        env.put( Context.SECURITY_AUTHENTICATION, "simple" );
        env.put( Context.INITIAL_CONTEXT_FACTORY, CoreContextFactory.class.getName() );
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.