How to show a Access Denied Page when User is not in Role?

Discussion in 'ASP .Net Security' started by Malik Asif Joyia, Jul 5, 2004.

  1. Hello
    I have Implemented the Forms Based Authentication and manageing Roles on the
    Directories.
    If a User is not in Role on some Sub directory of my Web-Application, How
    can i show the Access Denied Custom Designed Page......
    At this time if a user is logon to my web application and want to access
    some directory by giving its path in URL it redirects it to logon page...I
    want to avoid this thing as user is allready login. and Application should
    show the Access Denied Message.
    i have defined

    <authorization>
    <deny roles="1" />
    </authorization>


    in the web.config file of the sub directory

    Thanks
     
    Malik Asif Joyia, Jul 5, 2004
    #1
    1. Advertising

  2. Malik Asif Joyia

    Shaun Guest

    Did you find a solution to this problem - I have just run into the same thing today.

    Thanks

    Shaun

    "Malik Asif Joyia" wrote:

    > Hello
    > I have Implemented the Forms Based Authentication and manageing Roles on the
    > Directories.
    > If a User is not in Role on some Sub directory of my Web-Application, How
    > can i show the Access Denied Custom Designed Page......
    > At this time if a user is logon to my web application and want to access
    > some directory by giving its path in URL it redirects it to logon page...I
    > want to avoid this thing as user is allready login. and Application should
    > show the Access Denied Message.
    > i have defined
    >
    > <authorization>
    > <deny roles="1" />
    > </authorization>
    >
    >
    > in the web.config file of the sub directory
    >
    > Thanks
    >
    >
    >
     
    Shaun, Jul 9, 2004
    #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. Jesper Stocholm
    Replies:
    2
    Views:
    8,182
    John Saunders
    Aug 23, 2003
  2. Liet Kynes
    Replies:
    0
    Views:
    518
    Liet Kynes
    Nov 26, 2003
  3. Jens Jensen
    Replies:
    0
    Views:
    311
    Jens Jensen
    Jan 4, 2007
  4. zlf
    Replies:
    1
    Views:
    525
  5. Author
    Replies:
    7
    Views:
    1,161
    Author
    Feb 12, 2009
Loading...

Share This Page