locked
Impersonation issue. Exception from HRESULT: 0x80070005 (E_ACCESSDENIED) RRS feed

  • Question

  • User-760852804 posted

    I am impersonating a user through coding. (C#, ASP>NET2.0, windows 2003)

    The userid\password for person having permissions to access active directory has been  used to retrive the details of a particular AD user. This function works very well on the Domain Controller but it gives an error Exception from HRESULT: 0x80070005 (E_ACCESSDENIED) when deployed on domain Member server.

    The functions of AD access and manipulation are part of separate DLL and it is included in the presentation layer.


    Have searched a lot on this but could not find any resolution.


    Monday, April 9, 2007 9:11 AM

All replies

  • User-1573490007 posted
    I've been fighting with this for a while too. As far as I can tell, its because the impersonation can't "hop" from server to server. You need the actual machine to have the permissions, not a user. The only way I was able to get it to work is by adding the identity tag in my web config, and setting a static user and password there. To make things worse, that user can't just have "read only" access, it needs a lot more permissions than that (so far I've been working it out with the systadmins here, and it almost needs full permission on the container i'm trying to access).

    If anyone gets better results than that I'd be curious, as windows permissions are definately my weak spot.
    Monday, April 9, 2007 9:24 AM