forms authentication and wildcard mappings on UNC share

  • Thread starter Fabrizio Cipriani
  • Start date
F

Fabrizio Cipriani

I am trying to configure a UNC share where to put the files, since my
application is load balanced on a web cluster. I have configured the
application with forms authentication.

When I try to access files in the UNC share, the login form doesn't pop up.
I have also written a simple httphandler for testing purposes, but it isn't
invoked on the UNC share, while it is invoked for files in the application
root directory.

- The UNC share is defined as a virtual directory under the application root.
- I CAN open the files in the UNC share, it's just the authentication the
doesn't work

web.config in application root:
<?xml version="1.0"?>
<configuration xmlns="http://schemas.microsoft.com/.NetConfiguration/v2.0">
<appSettings/>
<system.web>
<httpHandlers>
<add verb="*" path="*.txt"
type="SecurityHttpHandler"/>
</httpHandlers>
<compilation debug="true" strict="false" explicit="true"/>
<authentication mode="Forms">
<forms name="appNameAuth" loginUrl="/dotnettest/login.aspx" protection="All"
/>
</authentication>
<identity impersonate="true" userName="rightname"
password="rightpassword"/>
</system.web>
</configuration>

web.config in UNC share:
<?xml version="1.0"?>
<configuration>
<connectionStrings/>
<location path="accesstest.txt">
<system.web>
<authorization>
<deny users="?"/>
<allow users="*"/>
</authorization>
</system.web>
</location>
</configuration>

When i try to access "accesstest.txt" authentication doesnt' kick in.

Thanks in advance,
Fabrizio Cipriani
 
F

Fabrizio Cipriani

just to keep this thread updated: creating another virtual directory
connected to the same UNC share did solve the problem.

I still have my old virtual dir with nothing different from the new one
except the name, but the old won't work, the new one will (authentication,
login.aspx, httphandler, everything is correctly invoked).

I'll keep the post updated, should I ever find the reason why.
f.c.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Staff online

Members online

Forum statistics

Threads
473,764
Messages
2,569,566
Members
45,041
Latest member
RomeoFarnh

Latest Threads

Top