Problems using AzMan role methods

Discussion in 'ASP .Net Security' started by Patrick Allmond, Nov 3, 2005.

  1. I am using AzMan and XML to do role, group and operation validation. This is
    all new to me, and I am working in VB. My application is using Windows
    Authentication. I have several questions:

    1. When trying to authenticate that the current user has access to an
    operation I use this code:
    Results = clientContext.AccessCheck("Object Being Audited Goes Here",
    Nothing, Operations, Nothing, Nothing, Nothing, Nothing, Nothing)
    (Operations is one element array with the operation id I want to check).
    After this call results(0) contains a 0 or 5. What are those supposed to
    translate to ? It looks like a 5 means the person is not authorized for the
    operation and a 0 means that they are. But I cannot find any good
    documentation on what a 5 vs a 0 means.

    2. Roles: I cannot get anything to work when it comes to role validation. A
    simple call such as:
    Dim temp() As String
    temp = Roles.GetAllRoles()

    results in:
    Unknown name. (Exception from HRESULT: 0x80020006 (DISP_E_UNKNOWNNAME

    I am pretty sure my web.config it set up correct but we can review if
    needed. I think it is OK because (as indicated in #1) I can check
    operations... somewhat.

    Thanks,
    Patrick
    Patrick Allmond, Nov 3, 2005
    #1
    1. Advertising

  2. Patrick Allmond

    Alfetta159 Guest

    "Zero indicates that the access check succeeded, and the client identified by
    the context is allowed to perform the specified operation. Any other value
    indicates failure (generally what you'll see is the number 5, which is
    ERROR_ACCESS_DENIED)."

    from:
    http://msdn.microsoft.com/msdnmag/issues/03/11/AuthorizationManager/

    "Patrick Allmond" wrote:

    > I am using AzMan and XML to do role, group and operation validation. This is
    > all new to me, and I am working in VB. My application is using Windows
    > Authentication. I have several questions:
    >
    > 1. When trying to authenticate that the current user has access to an
    > operation I use this code:
    > Results = clientContext.AccessCheck("Object Being Audited Goes Here",
    > Nothing, Operations, Nothing, Nothing, Nothing, Nothing, Nothing)
    > (Operations is one element array with the operation id I want to check).
    > After this call results(0) contains a 0 or 5. What are those supposed to
    > translate to ? It looks like a 5 means the person is not authorized for the
    > operation and a 0 means that they are. But I cannot find any good
    > documentation on what a 5 vs a 0 means.
    >
    > 2. Roles: I cannot get anything to work when it comes to role validation. A
    > simple call such as:
    > Dim temp() As String
    > temp = Roles.GetAllRoles()
    >
    > results in:
    > Unknown name. (Exception from HRESULT: 0x80020006 (DISP_E_UNKNOWNNAME
    >
    > I am pretty sure my web.config it set up correct but we can review if
    > needed. I think it is OK because (as indicated in #1) I can check
    > operations... somewhat.
    >
    > Thanks,
    > Patrick
    >
    Alfetta159, Jan 17, 2006
    #2
    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/OpenCanal\)

    AzMan: Has anyone created an HTML/Web management console as an alternative to the AzMan MMC?

    Michael Herman \(Parallelspace/OpenCanal\), Jan 6, 2006, in forum: ASP .Net Security
    Replies:
    0
    Views:
    240
    Michael Herman \(Parallelspace/OpenCanal\)
    Jan 6, 2006
  2. Bais

    Specify user for Azman/ADAM role manager

    Bais, Jan 11, 2006, in forum: ASP .Net Security
    Replies:
    5
    Views:
    177
  3. Kursat
    Replies:
    1
    Views:
    293
    Dominick Baier
    May 7, 2007
  4. need2scuba

    AzMan Role provider

    need2scuba, Jul 17, 2008, in forum: ASP .Net Security
    Replies:
    1
    Views:
    255
    need2scuba
    Jul 17, 2008
  5. Lars Sundstrom

    Azman. Unable to recive rolls from Azman.

    Lars Sundstrom, Oct 9, 2008, in forum: ASP .Net Security
    Replies:
    0
    Views:
    737
    Lars Sundstrom
    Oct 9, 2008
Loading...

Share This Page