Access denied while calling COM+ component from web wervice

Ask a Question related to ASP.NET Security, Design and Development.

  1. #1

    Default Access denied while calling COM+ component from web wervice

    Hello,
    I am trying to provide a web service layer on top of
    legacy VB 6.0 COM+ component. I will be calling my web
    service from ASP.NET pages (which are hosted on another
    web server) and web service will in turn invoke the COM+
    component.

    The problem is that I am receiving "Access Denied" error
    while calling COM+ component from web service. COM+
    component is a simple VB 6.0 component that runs under the
    identity of a domain account.

    This is what I did:

    (1) Installed VB 6.0 COM component in COM+ server
    application and set the Identity of the application (On
    Identity tab in COM+) to the domain account.
    (2) Created a RCW for the VB 6.0 component using tlbimp.exe
    (3) Created a web services project and added a reference
    to the previously created RCW
    (4) Called a method on web service that creates above
    mentioned RCW object and calls a method on it; as soon as
    the object creation call is run in web service method,
    System.UnauthorizedAccessException is raised.

    Important exception details are as follows:

    COMPlusExceptionCode ==>> 0xe0434f4d
    HResult ==>> 0x80070005
    Message ==>> "Access is denied."

    I have following software:
    * .NET Framework 1.1
    * Windows 2003 Enterprise Server (In production,
    application will run on Windows 2000 and .NET framework
    1.1)
    * IIS 6.0
    * COM+ 1.5

    I have following security settings:

    * IIS authentication is set to Annonymous
    * <authentication> mode is set to "None" in web service
    config file
    * Apart from that <authentication> element, web.config and
    machine.config files have all default settings; that means
    no impersonation, and request is run under default ASPNET
    account.

    What am I doing wrong here? Currently all component are on
    the same machine! Please help me out here; It is very
    urgent and I would really greatly appreciate any help in
    this regard.

    Thanks,
    Hidden Desi


    By the way, I have already gone through the following
    article (Knowledge Base Q325791)
    PRB: "Access Denied" Error Message Occurs When You
    Impersonate an Account in ASP.NET and Then Call STA COM
    Components

    According to this article:
    AspCompat is not available for Web Services (.asmx) so you
    must take a different approach. If the impersonated
    account is static, which means that you specify a userName
    and a password in the <identity> tag of Web.config or
    Machine.config, or if you always programmatically
    impersonate the same account, you can put the STA
    component in a COM+ Server Application and then set the
    identity of the application to the impersonated user.


    I also tried hard coding a domain user name and password
    in <identity> element in my web.config file but still the
    same error !!!

    Hidden Desi Guest

  2. Similar Questions and Discussions

    1. Web Service + Anon Access, but getting 401 Access Denied Error
      I have a simple webservice that just returns a string. The security for this is set to windows authentication in IIS (XP Professional) and anonymous...
    2. Access denied when calling COM component.
      Hello, I try to convert a VB6 application to an ASP Web application. This application uses a COM component to access data on a remote server. ...
    3. "Access is Denied" error when calling wshShell from ASP
      I've got a script in an ASP page that is supposed to extract certain files from a zip file, move them, create a new zip with the moved files and...
    4. Access denied when creating Access application object
      In an ASP file I am running the following in VBScript in order to extract data from an Access 2002 MDB file which is physically located in the...
    5. access denied on data access pages
      I have created data access pages that worked well when I tried them on two separate computer simutaneously, but when we went into production we got...
  3. #2

    Default Re: Access denied while calling COM+ component from web wervice

    “la solución más sencilla en ocasiones es la correcta”
    trukof Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139