AD Web Service Issue - InfoPath Dev
in

InfoPath Dev

AD Web Service Issue

Last post 02-13-2006 10:18 PM by Patrick Halstead. 8 replies.
Page 1 of 1 (9 items)
Sort Posts: Previous Next
  • 02-07-2006 07:50 AM

    AD Web Service Issue

    I recently installed the AD Web Service on a Windows XP computer running IIS. It appears to be installed properly and I can access thehttp://localhost/ADService/ADUserInfo.asmx page.
    When I invoke the GetMyInfo query I receive the following:
    <?xml version="1.0" encoding="utf-8" ?>
    <ArrayOfADProp xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xsi:nil="true" xmlns="http://tempuri.org/" />


    If I run the testconsole.exe from the command line I receive the following:
    ADProps is null or zero in length

    I verified that the LDAP value for my Domain is correct in the Web.config file and setup the IIS permissions for the ADService to Windows Authentication only.

    Is there something else I'm overlooking?
  • 02-07-2006 11:52 PM In reply to

    Hello Mike,
    This error is normally caused when the LDAP string is incorrect. Can you paste in the LDAP string that you gave while installing AD Service and also send the full computer name from the System Properties window (open it by right clicking on My Computer and click on Properties). Example of Full computer name is system3.GGK.com

    Shanthi
    InfoPath Dev India
    Shanthi Reddy
  • 02-07-2006 11:53 PM In reply to

    Also one other thing is - you are running it on a machine where you are logged into the domain right?

    Shanthi
    InfoPath Dev India
    Shanthi Reddy
  • 02-08-2006 10:12 AM In reply to

    Shanthi
    Thanks for the response. I am running the web service on a machine which is on the domain.
    I have pasted the information you requested:

    <add key="ActiveDirectoryPath" value="LDAP://DC=AVVENIREINC,DC=ENTERPRISE,DC=LOCAL" />

    Computer: TEST-XP.avvenireinc.enterprise.local

    I was able to get the invoke to work by changing the following line in the Web Config file:
    <identity impersonate="true" />
    Is this correct? After making this change I was able to set up an Infopath Form to retrieve the AD data, however if I go to another computer (on the domain) and access thehttp://testxp/ADService/ADUserInfo.asmx link the invoke button is not present. In addition if I run the testconsole.exe from this computer I am receiving an ADprops is null or zero in length error.
    Could this be an IIS security issue,.net framework issue or the WebConfig change I made to the file?
  • 02-08-2006 11:18 AM In reply to

    • Shyam
    • Not Ranked
    • Joined on 08-02-2005
    • Posts 10
    Gold,

    1) Are you saying that you were able to get the AD property values by clicking the "Invoke" button on the local machine ?
    2) "Invoke" button is available only on the local machine.
    3) When you run the TestConsole.exe from a different computer, just make sure the value of "ADServiceUrl" in "TestConsole.exe.config" file is set to "http://testxp/ADService/ADUserInfo.asmx"
    4) "Impersonate=true" part is not required if the userid under which ASP.NET worker process is running has permissions on ActiveDirectory.

    thanks, Shyam


    Shyam
    InfoPath Dev
    India
    Shyam
    InfoPath Dev
    India
  • 02-08-2006 11:44 AM In reply to

    Yes I was able to get the AD property values by both clicking on "Invoke" and from TestConsole.exe on the local machine only if I set the WebConfig to <identity impersonate="true" /> if I set this value to False then I do not get any results.
    I didn't realize that the invoke feature is only available on the local machine.

    On my other test computer I have verified that the TestConsole.exe.config file has the correct URL. I am able to set the Web Service as a data connection in Infopath but when I preview the form it is blank. If I run the testconsole.exe from this computer I am receiving an ADprops is null or zero in length error.
  • 02-09-2006 03:40 PM In reply to

    • jimbob
    • Top 500 Contributor
    • Joined on 11-26-2004
    • USA
    • Posts 32
    On Windows XP, setting the Application Protection for ADService to Low should be all that is required. This will run the ADService under the SYSTEM account. But in verifying this, I have discovered that the ADService was still getting executed in the worker process (aspnet_wp.exe) rather than inetinfo.exe. This may be caused by a Windows security update, but we will have to investigate further to determine if there are any workarounds for running on XP.

    Running the ADService on Windows Server 2003 should work without problems, as IIS 6 is easily configured for running under the service under the NETWORK SERVICE account.


    Jim Cantwell
    InfoPathDev - Redmond
    Jim Cantwell
    InfoPathDev - Redmond
  • 02-13-2006 08:10 AM In reply to

    I was able to resolve the issue with XP IIS. My intention was to use the AD Web Service on a Windows 2003 server with IIS6. I was using XP only for testing on a laptop. Using the article below I was able to use the Aspnet_setreg.exe utility to encrypt credentials and session state connection strings. After making the changes outlined in the below article I was then able to access the AD Web Service from remote computers on the network.

    http://www.kbalertz.com/Feedback.aspx?kbNumber=329290
  • 02-13-2006 10:18 PM In reply to

    Hi Mike,
    Thanks for the great reference and for adding to the common knowledge of this forum! :)

    Patrick Halstead [InfoPath MVP]
    InfoPath Dev Seattle
    Patrick Halstead
    Project Manager at Qdabra
Page 1 of 1 (9 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.