Re: Protect file with different extension from .aspx
From: Juan Antonio Tubío (jatubio_at_saluddigital.net)
Date: 03/30/05
- Next message: gabe garza: "Re: why not SQL Authentication?"
- Previous message: Juan Antonio Tubío: "Re: Protect file with different extension from .aspx"
- In reply to: gabe garza: "Re: Protect file with different extension from .aspx"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Wed, 30 Mar 2005 21:54:57 +0200
I think that the best solution is a 'mixed authentication' between
'windows authentication' and 'forms authentication'. Setup 'Windows
Authentication' to protect a full folder (automatically for all file
types) and when the user try to access them, show a login form (can
check the user in a custom database) and 'internally' do a 'Windows
Login' with a Windows User.
But i don't know hot to do it..
gabe garza escribió:
> Create an ASPX page that'll download the file to the user.
> Example. http://www.servername.com/getfile.aspx?filename=3928393293
>
> Now you can still use form authentication.
>
> Make sure in getfile.aspx to set your Content-Type and Content-Disposition
> properly.
>
> I did a similar thing for a client that wanted images sent from an AS/400
> computer to be displayed in a client browser, but only if a valid user was
> logged into the system.
> I also made sure that 3928393293 was only valid for the user that requested
> the image and that 3928393293 could only be used once. Some users bookmarked
> the URL but the client didn't want that.
>
>
> "Alessandro Zucchi" <AlessandroZucchi@discussions.microsoft.com> wrote in
> message news:396D536D-13DA-40A2-93DD-F26DE9C5B795@microsoft.com...
>
>>Hi,
>>I'm developing an asp.net application. I'm using form authentication.
>>All runs with page aspx, but when I try to connect to a protected file
>>diverse to an aspx (such as a PDF file) and I'm not authenticated , the
>>application download the file instead of redirect to the predefined login
>>page.
>>Anyone can help me ?
>>
>>Best regards
>>alex
>>
>>
>
>
>
- Next message: gabe garza: "Re: why not SQL Authentication?"
- Previous message: Juan Antonio Tubío: "Re: Protect file with different extension from .aspx"
- In reply to: gabe garza: "Re: Protect file with different extension from .aspx"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|
|