471,079 Members | 899 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,079 software developers and data experts.

Forms Authentication Problem in .Net 1.1

Hello Everyone and thanks for your help in advance. I
recently installed Visual Studio 2003 and .Net 1.1. I
then converted one of my applications to 2003. However,
I am running into a probelm with forms authenticaion. I
have set up certain subfolders that are proected and
should be redirected to a login page. However, when I
try to access the protected pages, I receive an HTTP 403
error, you are not authorized to view this page, rather
than a redirection to the login page. None of the code
has been changed, so I am not sure why this is
happening. Any help would be greatly appreciated
Jul 21 '05 #1
1 2904
Hi Hugh,

I hope I understand your question correctly. You want to have a web site
that requires forms authentication for some subfolders, but not for others.

I accomplished this with a "location" section in my web.config file. First,
I setup forms authentication for the whole site and verified that it was
working. Then I changed the web.config to allow anonymous users. Then I
added a location section which denied anonymous users to just the pages
that I wanted to protect.

Here is my location section which forces forms authentication for one page.
<location path="Deny.aspx">
<system.web>
<authorization>
<deny users ="?" />
</authorization>
</system.web>
</location>

Does this answer your question?

Thank you, Mike
Microsoft, ASP.NET

Microsoft highly recommends to all of our customers that they visit the
http://www.microsoft.com/protect site and perform the three straightforward
steps listed to improve your computerís security.

This posting is provided "AS IS", with no warranties, and confers no rights.
--------------------
Content-Class: urn:content-classes:message
From: "Hugh McLaughlin" <hu**@kmcnetwork.com>
Sender: "Hugh McLaughlin" <hu**@kmcnetwork.com>
Subject: Forms Authentication Problem in .Net 1.1
Date: Sun, 14 Sep 2003 16:16:12 -0700
Lines: 11
Message-ID: <03****************************@phx.gbl>
MIME-Version: 1.0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Newsreader: Microsoft CDO for Windows 2000
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
Thread-Index: AcN7FjBj42UZ8k0nTvyjZPDWq4XJ/g==
Newsgroups: microsoft.public.dotnet.general
Path: cpmsftngxa07.phx.gbl
Xref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.general:108139
NNTP-Posting-Host: tk2msftngxa09.phx.gbl 10.40.1.161
X-Tomcat-NG: microsoft.public.dotnet.general

Hello Everyone and thanks for your help in advance. I
recently installed Visual Studio 2003 and .Net 1.1. I
then converted one of my applications to 2003. However,
I am running into a probelm with forms authenticaion. I
have set up certain subfolders that are proected and
should be redirected to a login page. However, when I
try to access the protected pages, I receive an HTTP 403
error, you are not authorized to view this page, rather
than a redirection to the login page. None of the code
has been changed, so I am not sure why this is
happening. Any help would be greatly appreciated


Jul 21 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by Kris van der Mast | last post: by
reply views Thread by Anonieko Ramos | last post: by
7 posts views Thread by Justin | last post: by
5 posts views Thread by V. Jenks | last post: by
4 posts views Thread by =?Utf-8?B?R3V1czEyMw==?= | last post: by
4 posts views Thread by Bjorn Sagbakken | last post: by
5 posts views Thread by Rory Becker | last post: by
1 post views Thread by Sean | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.