Re: LDAP access to exchange 5.5

From: Jeff (jeff.hoch_at_abnamro.com)
Date: 02/19/04


Date: Thu, 19 Feb 2004 07:58:50 -0800

I am having a similiar problem using the same ldap query,
but my asp page returns a blank list. No addresses in th
recipient container are being returned.

Should the server name be the machine name of the server
or the exchange domain name.

Thanks
Jeff

>-----Original Message-----
>That cracked it - thank you very much for your help with
this matter.
>
>Richard
>
>"Wayne Harper [MSFT]" <wayneh@online.microsoft.com>
wrote in message
>news:eUiLWY53DHA.1760@TK2MSFTNGP10.phx.gbl...
>> Hello,
>>
>> Is Exchange 5.5 installed on a Windows 2000 domain
controller? If so,
>there
>> would be a conflict on port 389, and the Windows ldap
port (389) would
>> win out against the ldap protocol in Exchange. From
5.5 admin program,
>> expand your site, then expand configuration. Under
protocols, get
>> properties of LDAP. Verify the port number. If this
is a domain
>> controller, and the port is still set to 389, you must
change it to
>> something else, preferrably 390. Also, check the port
number under
>> servers/protocols/LDAP for server specific
information. If the port
>number
>> is OK, make sure you are using an account that has the
service account
>admin
>> role at the Org/site/configuration levels. You can
get properties of each
>> level (org/site/config) and go to the permissions tab
in the 5.5 admin
>> program. Use an account that has service account
admin role listed on
>each
>> level.
>>
>> Hope this helps!
>>
>> --
>> Wayne Harper [MSFT]
>> Microsoft Enterprise Messaging Support
>>
>> Please do not send e-mail directly to this alias.
This alias is for
>> newsgroup puposes only.
>> This posting is provided "AS IS" with no warranties,
and confers no
>rights.
>>
>>
>> "Richard Tappenden" <richardt@mailkey.nospam.com>
wrote in message
>> news:OJxBXl23DHA.2000@TK2MSFTNGP11.phx.gbl...
>> > Hi,
>> >
>> > I am currently trying to connect to my exchange 5.5
server via LDAP to
>> read
>> > the recipients list (and eventually to be able to
manage mailboxes).
>> >
>> > I have ran through various examples on the web and
those that are
>provided
>> > with the SDK. However, I nearly always
get 'Operations Errors'.
>> >
>> > I am pretty sure that my problem is authentication
related, and quite
>> > possibly a setup problem with my exchange server -
but being a
>developer,
>> I
>> > know nothing about the exchange setup :D.
>> >
>> > Could anyone offer some advice?
>> >
>> > Cheers,
>> >
>> > Richard
>> >
>> > p.s. - I have attached a small asp sample of what I
have been doing...
>> >
>> > strServerName = "MAILKEY-SBRQOD1"
>> > strUser = "Administrator"
>> > if strUser = "" then
>> > Response.Write "You are using Anonymous
authentication you will
>need
>> to
>> > change it so the user can be identified"
>> > Response.End
>> > end if
>> >
>> > set oConn = CreateObject("ADODB.Connection")
>> > set oCommand = CreateObject("ADODB.Command")
>> > set oRS = CreateObject("ADODB.Recordset")
>> >
>> > oConn.Provider = "ADsDSOObject"
>> > oConn.Open "Ads Provider"
>> >
>> > set oCommand.ActiveConnection = oConn 'set the
active connection
>> >
>> > ' Next we will build the LDAP query that will be
used to retrieve the
>> > contents of the GAL.
>> > ' We will specify which server we want to run the
query against,
>> > ' a filter for what types of objects we are looking
for, the attributes
>> we
>> > would like
>> > ' returned, and the type of search
>> > ' A filter of (objectClass=person) will return
mailboxes, distribution
>> > lists, and custom recipients
>> >
>> > strQuery= "<LDAP://" & strServername &
>> >
>>
>">;
(objectClass=person);cn,telephoneNumber,physicalDeliveryOf
ficeName,title,
>> > company,objectClass,uid;subtree"
>> > oCommand.CommandText = strQuery
>> > oCommand.Properties("Page Size") = 99 'a paged
query is used to
>avoid
>> > Exchange LDAP server limits
>> > set oRS = oCommand.Execute 'Execute the query
>> >
>> > Or I have also tried (in C++),
>> > hr = ::CoInitialize(NULL);
>> >
>> > hr =
>> >
>>
>ADsOpenObject(L"LDAP://mailkey-
sbrqod1/CN=Recipients,OU=Dev_Mailkey,O=Mailke
>> > y",
>> >
>> >
>>
>L"Administrator",L"mailkey",ADS_SECURE_AUTHENTICATION,IID
_IADs,(void**)&pDir
>> > Object);
>> >
>> >
>> >
>>
>>
>
>
>.
>



Relevant Pages

  • RE: MBSA and MSs attempts at "security"
    ... >the port status of TCP and UDP ports on a computer you choose. ... you can also query an LDAP service. ... LDAP query and interpret an LDAP server's response to ...
    (Focus-Microsoft)
  • Re: Vertrauensstellung kein Zugriff aufs AD
    ... TCP port 389: ... Sending LDAP query to TCP port 389... ...
    (microsoft.public.de.german.win2000.active_directory)
  • Re: Access Control to LDAP on AD?
    ... > hanging LSASS at 99% and investigation has found that there are developers ... > we can't just turn off access to LDAP, we have to see how we can prevent ... > recode their query, but I can't stop him from running it, and it's still ... >>> your corporate security policy. ...
    (microsoft.public.windows.server.security)
  • Re: Access Control to LDAP on AD?
    ... > hanging LSASS at 99% and investigation has found that there are developers ... > we can't just turn off access to LDAP, we have to see how we can prevent ... > recode their query, but I can't stop him from running it, and it's still ... >>> your corporate security policy. ...
    (microsoft.public.platformsdk.security)
  • Re: Access Control to LDAP on AD?
    ... > hanging LSASS at 99% and investigation has found that there are developers ... > we can't just turn off access to LDAP, we have to see how we can prevent ... > recode their query, but I can't stop him from running it, and it's still ... >>> your corporate security policy. ...
    (microsoft.public.security)