Re: File Types not protected by Forms Authentication
From: Brock Allen (ballen_at_NOSPAMdevelop.com)
Date: 06/17/05
- Next message: Danny Sanders: "Re: Event ID 1007 1084"
- Previous message: MatthewRoberts: "File Types not protected by Forms Authentication"
- In reply to: MatthewRoberts: "File Types not protected by Forms Authentication"
- Next in thread: John Timney \(ASP.NET MVP\): "Re: File Types not protected by Forms Authentication"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Fri, 17 Jun 2005 09:23:15 -0700
The reason is that IIS handles the requests for those files, not ASP.NET,
and IIS knows nothing about your intent from web.config. You'd have to route
that file extension through the aspnet_isapi.dll in IIS to have ASP.NET serve
it up.
-Brock
DevelopMentor
http://staff.develop.com/ballen
> Howdy All,
>
> We have an ASP.NET web application that uses Forms Authentication and
> has worked without problems for some time.
>
> However, we recently added a Shockwave SWF file to the mix for flash
> and interactivity.
>
> All ASPX, HTML, and other web files are protected by security. If you
> are not properly authenticated but try to access an ASPX or HTML file,
> you will be redirected to the Login page.
>
> However, if you try to access the SWF file directly, it allows you to
> view the animation without ever authenticating the user.
>
> Why is this? Are only certain file types protected for Forms
> Authentication? How can you add to that list of file types? Is it a
> MIME type or file extension we should be securing through IIS in some
> way?
>
> We even tried adding the following to the web.config file:
>
> <location path="OurAnimation.swf">
> <system.web>
> <authorization>
> <deny users="?" />
> </authorization>
> </system.web>
> </location>
> such that it should explicitly deny all anonymous, or unauthenticated
> users. But still, this did not work, and direct access to the file is
> allowed by anyone.
>
> Can anyone shed some light on this issue?
>
> Thank you in advance for whatever help you can provide.
>
> Matthew Roberts
> SOURCECORP
> Framework Architect
- Next message: Danny Sanders: "Re: Event ID 1007 1084"
- Previous message: MatthewRoberts: "File Types not protected by Forms Authentication"
- In reply to: MatthewRoberts: "File Types not protected by Forms Authentication"
- Next in thread: John Timney \(ASP.NET MVP\): "Re: File Types not protected by Forms Authentication"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|