Hi, I wrote a java libary from where functions are called by some JSP pages running under Tomcat 4.0.1. In this library, I use Sun's LDAP Control Extension for LDAP Sort Control (exported from com.sun.jndi.ldap.ctl.SortControl), as following:
ldapCtx = new InitialLdapContext(env, null); // Create the critical Sort control that sorts based on "uid" Control[] ctxCtls = new Control[] { new SortControl(new String[]{"uid"}, Control.CRITICAL) }; // Set the context's request controls to be ctxCtls ldapCtx.setRequestControls(ctxCtls); When I tested the code with a standalone java program (i.e., not running under Tomcat) it works just fine. However, when I run the code (called from a JSP page) under Tomcat 4.0.1, I got the following error: javax.naming.OperationNotSupportedException: [LDAP: error code 12 - Unavailable Critical Extension]; I put 'ldapbp.jar' under a few different places under Tomcat home directory, including 'lib', 'common\lib', etc. but got the same error. Any help you can give to get this resolved is appreciated. Thanks in advance. Best Regards, James Chiou