Restrict access to Classic ASP pages in web.config

Discussion in 'ASP .Net' started by Christiano, Jul 17, 2008.

  1. Christiano

    Christiano Guest

    Hi...

    I have an hybrid ASP/ASP.NET site... And it will be like this for a
    while...

    I need to authenticated these ASP pages with password too. How can I
    redirect it to login.aspx?

    I'm using this simple authentication/authorization rule...



    <system.web>

    <authentication mode="Forms">

    <forms name="Sinoreg_Login" loginUrl="login.aspx" timeout="20" />

    </authentication >


    <authorization>

    <deny users="?" />

    </authorization>

    </system.web>
     
    Christiano, Jul 17, 2008
    #1
    1. Advertising

  2. Christiano

    bruce barker Guest

    it will be a little tricky but not hard.

    your login.aspx page should store your own ticket and use an encryption that
    the asp code can decrypt and store the user name in it. in every asp page,
    check for the ticket, if there decode and get the username. if the ticket is
    not there redirect to the login page, passing the asp page name as the
    redirect url.


    -- bruce (sqlwork.com)


    "Christiano" wrote:

    > Hi...
    >
    > I have an hybrid ASP/ASP.NET site... And it will be like this for a
    > while...
    >
    > I need to authenticated these ASP pages with password too. How can I
    > redirect it to login.aspx?
    >
    > I'm using this simple authentication/authorization rule...
    >
    >
    >
    > <system.web>
    >
    > <authentication mode="Forms">
    >
    > <forms name="Sinoreg_Login" loginUrl="login.aspx" timeout="20" />
    >
    > </authentication >
    >
    >
    > <authorization>
    >
    > <deny users="?" />
    >
    > </authorization>
    >
    > </system.web>
    >
    >
    >
     
    bruce barker, Jul 17, 2008
    #2
    1. Advertising

  3. Christiano

    Christiano Guest

    bruce...

    it worked...

    tks a lot..
    christiano



    "bruce barker" <> escreveu na mensagem
    news:...
    > it will be a little tricky but not hard.
    >
    > your login.aspx page should store your own ticket and use an encryption
    > that
    > the asp code can decrypt and store the user name in it. in every asp page,
    > check for the ticket, if there decode and get the username. if the ticket
    > is
    > not there redirect to the login page, passing the asp page name as the
    > redirect url.
    >
    >
    > -- bruce (sqlwork.com)
    >
    >
    > "Christiano" wrote:
    >
    >> Hi...
    >>
    >> I have an hybrid ASP/ASP.NET site... And it will be like this for a
    >> while...
    >>
    >> I need to authenticated these ASP pages with password too. How can I
    >> redirect it to login.aspx?
    >>
    >> I'm using this simple authentication/authorization rule...
    >>
    >>
    >>
    >> <system.web>
    >>
    >> <authentication mode="Forms">
    >>
    >> <forms name="Sinoreg_Login" loginUrl="login.aspx" timeout="20" />
    >>
    >> </authentication >
    >>
    >>
    >> <authorization>
    >>
    >> <deny users="?" />
    >>
    >> </authorization>
    >>
    >> </system.web>
    >>
    >>
    >>
     
    Christiano, Jul 18, 2008
    #3
    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. Nathan Sokalski
    Replies:
    5
    Views:
    1,044
    Gaurav Vaish \(www.Edujini-Labs.com\)
    Jan 10, 2007
  2. mase
    Replies:
    11
    Views:
    1,231
    Michael Nemtsev
    Jul 4, 2007
  3. Nathan Sokalski
    Replies:
    4
    Views:
    314
    Nathan Sokalski
    Dec 21, 2006
  4. Nathan Sokalski
    Replies:
    4
    Views:
    352
    Nathan Sokalski
    Dec 21, 2006
  5. chris
    Replies:
    2
    Views:
    133
    kaeli
    Nov 10, 2003
Loading...

Share This Page