Click to See Complete Forum and Search --> : ASP and LDAP


jacknbey
05-06-2005, 03:43 AM
Hi all,

Can anyone give me some guides over the LDAP support using ASP?

In any case if the ASP cannot support LDAP which other language you normally use and how this "language" going to interact with ASP pages?

Regards,
Jack

lmf232s
05-06-2005, 03:37 PM
there are some examples on the web for using LDAP in asp pages.
I had played around with it for a little bit but never got around to finishing it.
I would just google (asp LDAP) and you should get some hits.

phpnovice
05-07-2005, 09:58 AM
In any case if the ASP cannot support LDAP which other language you normally use and how this "language" going to interact with ASP pages?
LDAP is not a language -- it is a protocol. To use anything other than the HTTP protocol with ASP, you'll need to instantiate a separate COM object to perform that function on behalf of your ASP code. An example is the SMTP protocol (for mail). CDONTS, CDOSYS, ASPmail, and JMail are all examples of separate COM objects which perform a portion of the SMTP protocol functions on behalf of ASP. Even the file-level protocols (shall we call them) each require a COM object -- FSO for the file system and ADO (or something similar) for the database system.

In the case of LDAP, it just so happens that ADO can help you there. For example:

SQLStmt = "SELECT cn " & _
"FROM 'LDAP://LDAPSERVER:1003/o=microsoft/ou=members' " & _
"WHERE objectClass='*'"

In the above, you'll note that the protocol (LDAP:) is specified.

Querying an LDAP Server using Active Directory and ADO (http://www.4guysfromrolla.com/webtech/041800-1.shtml)

Also in the above, LDAPSERVER represents the name of your LDAP/ADSI Server and 1003 is the port you wish to use to communicate with that server. These things must be according to information your server administrator(s) supply to you. This is, of course, referring to an intranet environment. ;)