Solved

CFLDAP Query

Posted on 2011-02-10
4
925 Views
Last Modified: 2012-08-14
Hi Guys,

I am trying to get a CFLDAP Query working.

Code:

<cfldap action="query"
           server="SERVER"
           name="ADResults"
           start="DC=DOMAIN NAME"
           filter="(&(objectclass=user)(SamAccountName='user'))"
           username="username"
           password="password"
           attributes = "cn,o,l,st,sn,c,mail,telephonenumber, givenname,homephone, streetaddress, postalcode, SamAccountname, physicalDeliveryOfficeName, department">

Using <cfoutput query="ADResults">
#cn# #o# etc
</cfoutput>

No error and no results shown.
0
Comment
Question by:forcecorp
  • 3
4 Comments
 
LVL 3

Accepted Solution

by:
sajayc earned 500 total points
ID: 34867458
Hi,

If you do a cfdump of ADResults, what do you get? An empty structure?

Also in your start variable, you might need to put more info in to get further down the tree.
On our network we have it setup as: ourdomain.local
We used this as the start value: cn=users,dc=ourdomain,dc=local

Hope this helps,

Thanks,
0
 

Author Comment

by:forcecorp
ID: 34867544
I have tried tasking it down to the folder my own account is in, and is still does not return any results.

Have tried with dc=domain,dc=local
and dc=fqdn
and dc=domain controller

all return no results.
0
 

Author Comment

by:forcecorp
ID: 34867687
found the answer.

Using FQDN ====  DC=internal domain name(subdomain), DC=external domain name -.com.au, DC=com, DC=au
0
 

Author Closing Comment

by:forcecorp
ID: 34867688
start="DC=mysubdomain,DC=mydomain,DC=com,DC=au"
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Restoring deleted objects in Active Directory has been a standard feature in Active Directory for many years, yet some admins may not know what is available.
This article shows how to deploy dynamic backgrounds to computers depending on the aspect ratio of display
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.

820 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question