« Previous Next »

Thread: Microsoft.Web.Administration - Access denied on remote call

Last post 07-04-2009 4:40 PM by debol. 2 replies.

Average Rating Rate It (5)

RSS

Page 1 of 1 (3 items)

Sort Posts:

  • 08-01-2008, 5:13 AM

    • KlausE
    • Not Ranked
    • Joined on 07-25-2008, 9:33 AM
    • Duesseldorf, Germany
    • Posts 2

    Microsoft.Web.Administration - Access denied on remote call

    I am using ServerManager.OpenRemote to access a remote IIS. See the code sample below:

    using( ServerManager manager = ServerManager.OpenRemote( serverName ) )

    {

      foreach( Site site in manager.Sites )

      {

        Console.WriteLine( @"Site: " + site.Name );    foreach( Application app in site.Applications )

        {

          Console.WriteLine( @" " + app.Path );

        }

      }

    }

    My PC is running Vista Business Edition SP1 Englisch. I have the IIS Manager (from the download section on this page) installed. I can connect to the IIS on my machine using the code sample above. I can as well connect to another Vista Machine in the same domain using my domain account or using local accounts with the same name and password.

    Now I am trying to connect to Windows Server 2008 machines in a workgroup separated by a firewall. I have configured a fixed endpoint for AhAdmin DCOM application as described in the following article http://mvolo.com/blogs/serverside/archive/2008/05/26/Accessing-IIS-7.0-configuration-remotely-and-on-server-core.aspx.

    The firewalls on the Windows Server 2008 machines are disabled. The firewall between the workgroup and the domain with my PC allows TCP port 135 for the DCOM port mapper and the fixed endpoint port.

    When ever I run the code sample from my machine I get an UnauthorizedAccessException. I am running this code with a user that exists on the remote machines as well. I can connect to the IIS remotely with the local user using the ISS Manager. I can logon to the IIS with this user using RDP. The local user on the Windows Server 2008 machine is an Administrator.

    To ensure that this is not a firewall issue, I have now run the code sample on one Windows Server 2008. It can connect to localhost but not to a 2nd Windows Server 2008 in the same workgroup.

    Does any one have an idea what causes the UnauthorizedAccessExeption? The error message of the exception is:

    Retrieving the COM class factory for remote component with CLSID {2B72133B-3F5B-
    4602-8952-803546CE3344} from machine 10.49.5.14 failed due to the following erro
    r: 80070005.

    Thanks in advance

    Klaus

  • 08-06-2008, 3:23 AM In reply to

    • KlausE
    • Not Ranked
    • Joined on 07-25-2008, 9:33 AM
    • Duesseldorf, Germany
    • Posts 2

    Re: Microsoft.Web.Administration - Access denied on remote call

    Update: 

    I have opened a microsoft support call. The support engineer adviced to disable the UAC (User Access Control). However, this is not a sufficient solution. As microsoft recommends that UAC is enable, my manager regards disabling UAC as weakening the server. Is there another way, how I can get access to the remote server?

     

  • 07-04-2009, 4:40 PM In reply to

    • debol
    • Not Ranked
    • Joined on 02-07-2008, 12:17 AM
    • Posts 1

    Re: Microsoft.Web.Administration - Access denied on remote call

    By default the domain administrator has not enough rights to update IIS7 config files
    (%Windows%\System32\inetsrv\Config).
    You can create a special user with the rights to update IIS config folder, then
    call the function in contex of the user or write WebServices.
    When you write a WebServices, it is important to add to the web.config file
    <identity impersonate="true"/>, then run webservices function, from a client application,
    with the user credentials.

Page 1 of 1 (3 items)
Microsoft Communities