AzAuthorizationStore.Initialize on ADAM Url throws FileNotFoundException

Discussion in 'ASP .Net Security' started by Jared Warren, Sep 9, 2006.

  1. Jared Warren

    Jared Warren Guest

    I have an ADAM instance with a root of
    "CN=TestWithRoles,DC=royalroads,DC=ca" running on a server called
    metrocsdev, port 5000. I successfully connect to this remotely using
    AdsiEdit. This instance contains an AzMan store, which I have
    successfully edited using the AzMan tool. However, when I try running
    the following C# code in a console app:

    AzAuthorizationStore apps = new AzAuthorizationStoreClass();
    apps.Initialize(0,
    "msldap://metrocsdev:5000/CN=AzManStore,CN=TestWithRoles,DC=royalroads,DC=ca",
    null);

    I get a FileNotFoundException: The system cannot find the file
    specified. (Exception from HRESULT: 0x80070002). Why is my url not
    being parsed correctly?

    Thanks for your help.
    Jared Warren
    Metro Project, Royal Roads University
    Jared Warren, Sep 9, 2006
    #1
    1. Advertising

  2. Jared Warren

    Chi-Yan Tong Guest

    I have the exact same problem. Seems like if you add an ADAM user (not
    Windows user) to the Role Assignments though the AzRoles API, then you
    cannot initialize the AzAuthorizationStore again on the next
    application run without getting that error message you mentioned. This
    is because the AzRoles API doesn't recognize the ADAM user SID when
    initializing (though it should never need to access that information
    upon initialization).

    Now, does anybody know how to resolve this issue? That is, how can we
    still call initialize on an AzMan store that has ADAM users assigned to
    its roles?

    Thanks,
    Chi
    Chi-Yan Tong, Sep 11, 2006
    #2
    1. Advertising

  3. Jared Warren

    Andy H Guest

    RE: AzAuthorizationStore.Initialize on ADAM Url throws FileNotFoundExc

    Jared,

    I had this same problem. It is a permissions issue. You need to do the
    following:

    1) In ADSI-Edit, your ADAM partition has a Roles container. Inside that is
    Readers. Edit the "members" attribute of Readers, and add whatever AD Groups
    and Users will be running your console app. This gives them access to the
    ADAM partition.

    2) In Authorization Manager, right-click on your store and click Properties,
    go to the Security tab. In there, select the Reader role and add the same AD
    Users and Groups you added in step 1. This gives them permission to call
    AccessCheck.
    Andy H, Nov 9, 2006
    #3
  4. Jared Warren

    Andy H Guest

    Andy H, Nov 9, 2006
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Michael Herman \(Parallelspace\)

    ASP.NET 2.0, MS AD/ADAM and Authorization Manager (AzMan)

    Michael Herman \(Parallelspace\), Jul 6, 2005, in forum: ASP .Net
    Replies:
    1
    Views:
    874
    Michael Herman \(Parallelspace\)
    Jul 9, 2005
  2. =?Utf-8?B?RQ==?=
    Replies:
    0
    Views:
    1,002
    =?Utf-8?B?RQ==?=
    Nov 17, 2005
  3. =?Utf-8?B?SmFtZXMgQ29sZW1hbg==?=

    ADAM and AzMan with ASP.NET 2.0

    =?Utf-8?B?SmFtZXMgQ29sZW1hbg==?=, Feb 24, 2006, in forum: ASP .Net
    Replies:
    0
    Views:
    590
    =?Utf-8?B?SmFtZXMgQ29sZW1hbg==?=
    Feb 24, 2006
  4. =?Utf-8?B?c2hpa2FyaXNoYW1idQ==?=

    ASP.NET - SEcurity Configuration with ADAM error

    =?Utf-8?B?c2hpa2FyaXNoYW1idQ==?=, Mar 31, 2006, in forum: ASP .Net
    Replies:
    0
    Views:
    506
    =?Utf-8?B?c2hpa2FyaXNoYW1idQ==?=
    Mar 31, 2006
  5. Ryan Stewart

    URL and FileNotFoundException

    Ryan Stewart, Dec 7, 2004, in forum: Java
    Replies:
    2
    Views:
    1,768
    Ryan Stewart
    Dec 8, 2004
Loading...

Share This Page