java - JBoss connection configuration for LDAP -


i want use jboss 7.1 server's connection pooling configure ldap server. writing java program connect ldap server configured in above step , retrieve user information. java class part of war file deploying same jboss server later on. can xml file in location needs modified have ldap information , small code snippet in java class reads configurations , connects ldap server. ahve simple in java file connects ldap server , gets info. shown below:

        hashtable env = new hashtable();           env.put(context.initial_context_factory,                   "com.sun.jndi.ldap.ldapctxfactory");           env.put(context.security_authentication, "simple");           env.put(context.security_principal, "cn=manager, dc=maxcrc,dc=com");           env.put(context.security_credentials, "secret");           env.put(context.provider_url, "ldap://localhost:389"); 

also if have password encrypted in config file there utility provided jboss framework decrypt password while connecting server or should write method in java class decrypt , send across. won't using jboss ldap authentication. saw posts login-config files won't situation. thanks.

i'm out of time test believe need use externalcontext achieve goal.

see link: https://access.redhat.com/site/documentation/en-us/jboss_enterprise_web_platform/5/html/administration_and_configuration_guide/additional_naming_mbeans-org.jboss.naming.externalcontext_mbean.html

then see this: https://community.jboss.org/thread/175856

i believe way :)

best, -- mauricio


Comments

Popular posts from this blog

c# - Operator '==' incompatible with operand types 'Guid' and 'Guid' using DynamicExpression.ParseLambda<T, bool> -