Ask a Question related to Coldfusion - Advanced Techniques, Design and Development.
-
Howard Perlman #1
LDAP - Same error ever time
I need to make my first CFM file to read from an LDAP server.
All I ever get is Connection to LDAP Server failed errors.
I've gotten complete code to do an LDAP retrieval, a number of times, and I
always seem to get the same error. This is code to access public LDAPs. Some of
the code I gotten right from CF documentation.
Ideas on this?
For example, here is the code for my last attempt.
Thanks!
Howard Perlman
US Geological Survey
<html><body>
<h3>cfldap Example</h3>
<p>Provides an interface to LDAP directory servers. The example uses the
University of Connecticut public LDAP server. For more public LDAP servers,
see <a href="http://www.emailman.com">http://www.emailman.com</a>.</p>
<p>Enter a name and search the public LDAP resource.
An asterisk before or after the name acts as a wildcard.</p>
<!--- If form.name exists, the form was submitted; run the query --->
<cfif IsDefined("form.name")>
<!--- check to see that there is a name listed --->
<cfif form.name is not "">
<!--- make the LDAP query --->
<cfldap
server = "ldap.uconn.edu"
action = "query"
name = "results"
start = "dc=uconn,dc=edu"
filter = "cn=#name#"
attributes = "cn,o,title,mail,telephonenumber"
sort = "cn ASC">
<!--- Display results --->
<center>
<table border = 0 cellspacing = 2 cellpadding = 2>
<tr>
<th colspan = 5>
<cfoutput>#results.recordCount# matches found
</cfoutput></TH>
</tr>
<tr>
<th><font size = "-2">Name</font></TH>
<th><font size = "-2">Organization</font></TH>
<th><font size = "-2">Title</font></TH>
<th><font size = "-2">E-Mail</font></TH>
<th><font size = "-2">Phone</font></TH>
</tr>
<cfoutput query = "results">
<tr>
<td><font size = "-2">#cn#</font></td>
<td><font size = "-2">#o#</font></td>
<td><font size = "-2">#title#</font></td>
<td><font size = "-2">
<A href = "mailto:#mail#">#mail#</A></font></td>
<td><font size = "-2">#telephonenumber#</font></td>
</tr>
</cfoutput>
</table>
</center>
</cfif>
</cfif>
<form action="#cgi.script_name#" method="POST">
<p>Enter a name to search in the database.
<p>
<input type="Text" name="name">
<input type="Submit" value="Search" name="">
</form>
</body>
</html>
Howard Perlman Guest
-
Odd LDAP Error when testing config
I'm stuck and hoping someone might have an idea what's going on. I deployed the CPS as a WAR onto our Oracle Application Server, since that's what... -
Size Limit Exceeded error when querying ldap
I am receiving the following error when trying to use ldap to return a list of email addresses from outlook. If I put in a filter the error goes... -
Error when using ldap query
I am trying to do an LDAP query an AD group. I already have one that queries the same server, and works. But on my new query I get the following... -
error 80005000 when querying LDAP
I'm using ASP and CDO to lookup free busy time on an e2k server. The E2K is locally installed on the IIS server and I'm having no problems... -
Error Access LDAP from outside the Network with authenticated User
Im using IIS and ASP and am forcing user authentication. I have the webserver in the same forest as the LDAP server, but the domain that the LDAP... -
jorgepino #2
Re: LDAP - Same error ever time
I had the same problem, but it happend it was not the cfladp but in the way my
network is setup,
I had to try several way to connect
server = "servername.com" or server = "123.45.678 or server = "Machine_name"
or the user = "username" or user = "username@servername.com" or user =
"Machine_name/username"
instialling a local Ldap prgram in your PC can help you find what is the
correct connection
I use softterra ldap browser it is free
[url]http://www.ldapbrowser.com/[/url]
jorgepino Guest



Reply With Quote

