| | |
| | | * @param ldapUrl the ldap URL of the server. |
| | | * @param dn the dn to be used. |
| | | * @param pwd the password to be used. |
| | | * @param timeout the timeout to establish the connection in milliseconds. |
| | | * Use {@code 0} to express no timeout. |
| | | * @return <CODE>true</CODE> if we can connect and read the configuration and |
| | | * <CODE>false</CODE> otherwise. |
| | | */ |
| | | public static boolean canConnectAsAdministrativeUser(String ldapUrl, |
| | | String dn, String pwd) |
| | | String dn, String pwd, int timeout) |
| | | { |
| | | return ConnectionUtils.canConnectAsAdministrativeUser(ldapUrl, dn, pwd); |
| | | return ConnectionUtils.canConnectAsAdministrativeUser(ldapUrl, dn, pwd, |
| | | timeout); |
| | | } |
| | | |
| | | /** |
| | |
| | | return msg; |
| | | } |
| | | |
| | | /** |
| | | * Returns the default LDAP timeout in milliseconds when we try to connect to |
| | | * a server. |
| | | * @return the default LDAP timeout in milliseconds when we try to connect to |
| | | * a server. |
| | | */ |
| | | public static int getDefaultLDAPTimeout() |
| | | { |
| | | return ConnectionUtils.getDefaultLDAPTimeout(); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * Returns the path of the installation of the directory server. Note that |