Wrox Home  
Search P2P Archive for: Go

  Return to Index  

asp_web_howto thread: Hiding URL to file download


Message #1 by "Jenifer Mundstock" <jenifer@s...> on Wed, 12 Sep 2001 23:47:32
Hi all,

I'm having a dilemma and am looking for any help anyone can give.  My 

client has a software application that they sell that has a specific 

serial number associated with it.  They want to be able to offer the 

customer a ONE-TIME download of the upgrade for customers with the valid 

serial number. My problem is that my client also does not want the 

customer to be able to view the source of the page to see the link to the 

executable file.

 

I tried doing a redirect to the exe file and the download worked on my 

system through IE and Netscape, but Mac users seem to NOT get the download 

file but they get the actual asp file downloaded instead (eek).

 

Do you have any ideas on how other people are implementing this kind of 

thing?  Is this even possible?



Any help is MUCH appreciated!

Jenifer



----------------------------------

Message #2 by "Andy Ness" <aness@e...> on Wed, 12 Sep 2001 16:37:57 -0700
You could bury the download.exe a few levels down like this:



www.yourserver.com/your/download/f/i/l/e/goes/here/download.exe



Then mask the path using:



Server.MapPath("/your/download/f/i/l/e/goes/")



Then the hyperlink might look something like <a

href="/here/download.exe">Click to Download</a>



Then reset the MapPath back to the normal Root afterwards like this:



Server.MapPath("/")



so that your other hyperlinks will work and be referenced from the virtual

root directory of the server.

I have not tested this, but it should work. Good luck!

Andy Ness





-----Original Message-----

From: Jenifer Mundstock [mailto:jenifer@s...]

Sent: Wednesday, September 12, 2001 11:48 PM

To: ASP Web HowTo

Subject: [asp_web_howto] Hiding URL to file download





Hi all,

I'm having a dilemma and am looking for any help anyone can give.  My

client has a software application that they sell that has a specific

serial number associated with it.  They want to be able to offer the

customer a ONE-TIME download of the upgrade for customers with the valid

serial number. My problem is that my client also does not want the

customer to be able to view the source of the page to see the link to the

executable file.



I tried doing a redirect to the exe file and the download worked on my

system through IE and Netscape, but Mac users seem to NOT get the download

file but they get the actual asp file downloaded instead (eek).



Do you have any ideas on how other people are implementing this kind of

thing?  Is this even possible?



Any help is MUCH appreciated!

Jenifer





Message #3 by "Simon Umbricht" <simon@p...> on Thu, 13 Sep 2001 08:48:58
hi there



here's i'd try to solve the problem: hide the download.exe file in a folder that's NOT 

shared through IIS, then use the Scripting.FileSystemObject object to binary read 

out the file and write it into the response. you just have to make sure you set the 

correct mime type for the response.

this way no one can see the url of download.exe, but they can see download.asp, 

so you should build in a check, and maybe even a database that stores all the 

serial numbers of the users that have already downloaded the upgrade.



i hope this helps you. let me know if it works.



simon <simon@p...>

  Return to Index