IIS Virtual Directory/Application & Forms authentication
Posted
by user216194
on Stack Overflow
See other posts from Stack Overflow
or by user216194
Published on 2010-05-30T00:53:17Z
Indexed on
2010/05/30
1:02 UTC
Read the original article
Hit count: 283
I've setup and deployed a simple forms authentication website with membership using .NET 4.
I've created a virtual directory (now converted to "Application") in IIS7 and setup the web.config
file in the virtual directory as follows:
<system.webServer>
<directoryBrowse enabled="true" />
</system.webServer>
Great! I browse to the virtual directory: ../mydomain/books/
and I'm automatically redirected to the login page specified by web.config
in my root directory and the url path is placed as follows:
../Account/Login.aspx?ReturnUrl=%2fbooks
At this point, I login succesfully, but I am not redirected anywhere, and when I manually return to the directory, ../books
, I'm sent back to the login page, where I'm already logged in?
So I'm confused about what my problem is! I should be successfully authenticated, and than redirected back to the directory, or at the very least be able to view it manually after I log in right?
© Stack Overflow or respective owner