Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
 
  HOME    TRACKER    ASP




How To Avoid Downloading A File Directly From Webserver ?


I need to provide a way to download a software and its corresponding
manual from a web page.

So far I have done the sign in page where people give their data. I
will then give access to a page with a link allowing to download the
required file(s).

My worry is how to avoid that somebody grabs the URL of the file and
send it to another for downloading directly from the server. What can
I do to avoid this ?




View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread
Avoid Address Bar File Addressing
I want to avoid client to open a file from my site by typing its path in their address bars . Is there any solution for that?

Could Not Run Asp File On My Webserver
I am using windows 2000 server with IIS already install. I have copied test.asp file to wwwroot directory and tried to run it but it did not work ..and i gave me this error msg.

http://localhost/test.asp
or
http://127.0.0.1/test.asp
or
http://my_server_name_here/test.asp

The page cannot be displayed There is a problem with the page you are trying to reach and it cannot be displayed. HTTP 500 - Internal server error Internet Explorer

I have even tried to run the iisstart.asp and localstart.asp which already
exist at wwroot directory when IIS is installed.However, it still could not work.

Does anyone know why ? I how do i know that the webserver and ASP engine is working properly.

ASP Force Download Of File From Webserver
I am creating an asp application which is essentially a file management app. I am trying to get my head around a technically issue wonder if someone can offer some help.

I want to be able to force the download of the files are attached to a particular record.
The code which i use to force the download is:

<%
strPath = "C:MyFiles"
Set Upload = Server.CreateObject("Persits.Upload")
' Build path to file
strPath = uploadfilepathactual
Path = strPath & "" & strFileName
Upload.SendBinary Path, True, "application/octet-binary", True
%>

I want to be able to change the path to say something like

strPath = servernamec$myfiles

Is the above possible. Any other alternatives.

How Do I Install A MSI File From Webserver On The Client Machine.
I have a web server running on a machine. When the users
connect to that machine, it loads the ASP page. The ASP
page has a ActiveX control on it and it gets downloaded to
the client's machine. I have made the control as a signed
control so there is no problem in download.

Likewise, in the virtual directory path on the server, I
have one clientsettings.MSI and that needs to be run on
the server. Whenever the user tries to connect to the web
page, in onload event of the web page, the .MSI file
should be installed on the clients machine. For this to
happen what all needs to be done ?

Downloading A File
There any way to download files I'm keeping stored above the www
folder for security

I'm thinking of the following : My script determines what file the user
requests, checks their credentials, and then "forwards" the file from the
non public directory to the user.



Downloading Pdf File
From the client side, I want to download a pdf file from the server side that was initially saved there.

this site didnt work for me: ....

Downloading A File
I have a download function that allows a site visitor to download a file. It works when the page that calls the function, the function, and the file to download are all in the same folder. I want to be able to have the page that calls in one folder, the function in another folder and the file in a third. Any advice? Code that is working when all three are together:

Function doDownload (fileName)
dim myAttachment
myAttachment = "attachment; filename=" & fileName
Response.AddHeader "Content-Disposition", myAttachment
Response.ContentType = "application"
response.BinaryWrite fileName

End Function

Automatic File Forwarding From Webserver To Local Server
Having finally mastered freeASPUpload, I really want the files being uploaded to the web server to automatically be forwarded to my local inhouse server. I'm sure there has to be a way.

Downloading Or Opening A File In Asp
I want to create a asp page where i can give the user an option of downloading a file or opening a file e.g an excel file.

How do i do this?? Ive already created an asp page which has a button- where the user can click on the button. The excel option of either opening the file or downloading it comes up- but i want this option actually on a asp page. How do I go about this?

File Downloading Problem In Firefox.
i am having prob while downloading a file in firefox. If the filename contains
spaces it takes only name before the first space. The rest of the part in the filename is egnored....

i use the following code for it.
--
Response.Addheader "Content-Disposition", "attachment; filename=" & filename
----
example if the filename is "sample filename.doc". while downloading it saves as "sample" the rest of the part filename.doc is removed.

The above code works fine in IE. Can anyone here tell me how i can handle this in firefox v1.

How To Redirect The User To New Page After Downloading An Mp3 File
I have set of mp3 files as a list (DownloadFiles.asp). The user can click on any of the mp3 files to download(Download_Porcess.asp).After downloading the file the user has to redirect to the DownloadFiles.asp.

For this i used:

response.contenttype="audio/mpeg3",
response.binarywrite("binarystreamofmp3file)

In Download_Process.asp to force the save dialog box. This works fine. This allows the user to download the file. After downloading this mp3 file, this file should not be displayed in the list ie in (DownloadFiles.asp).

How can i do this?

I am not able to redirect from Download_Process.asp to DownloadFiles.asp, b'coz I used response.binarywrite.

Unable To Browse Website While Downloading A File Using A Component
I've been trying to send a (large) file to the browser via a download
page that uses a file download component. The file downloads fine,
except that Internet Explorer refuses to browse to a different page
while the file is downloading! I don't understand why it does that
and I don't know how to fix this problem.

Any idea? Code:

Directly From URL
I have the page "content.asp" and it is called from the "menu.asp" page.
Two page are on diffenent servers and on different Databases.
Users who request the content.asp page are authenticated when they enter the
"menu.asp" page.
So, if another authentication is required when users enter "conent.asp", it
is redundent, I think.
Finally, I want to reject users requests for content.asp if the page
"contnet.asp" is requested directly from URL.
Are there ways if the page content.asp is called from URL or the <a> tag in
the menu.asp?

Directly Download Program
When somebody downloads my Setup Program from my Web-Site they are taken to a blank page first so that I can use this to record the download hits, then the download window comes up.

How can it be done so that when somebody clicks on the download link, the download window comes up, but by this stage I have recorded this as a download hit,without having to display a blank page on the browser first?

Edit Database Directly
I'm keen to learn how to do some simple asp script so that I can access my customer database over the internet from various locations.

I want to know how to write the appropriate script into an html form (I use MS Frontpage as an editor) so that when I log in to my site I will be able to see and edit this database directly on the net without having to download the file for editing, then upload it again until next time.I understand that I will have to save my database as a MS Access file (*.mdb) because this format will work better with asp commands.

If you know of an online Dummies Guide to ASP please let me have the link so I can learn some of the basics without having to bore you with working through all that.

Directly Pass Parameters To Post
In order to test some pages of mine, is possible to directly hard-code a request passing some parameters in a post method to an asp page?

Bypass ODBC Server And Connect To .MDB Directly
Theres a script that bypasses ODBC and connects directly to .mdb database for asp scripts , is anyone familiar with this? I dont even know if its a .asp script.

Convert Html From Url To Pdf Directly Into Response Object?
I'm looking for an activex com that will be given an existing url and turn it into pdf binary stream (no files on the server) either that or turn into a tiff image.

I would like something that has a small footprint meaning no impersonation, no visual screens, just pure sdk ...

Save Export Excel Directly To My Server Without Prompting
Does anyone know how to save an export excel file to the server automatically without any prompting and opening of the excel file?

Because I'm doing archiving, I need to let the user click on the archive button and the exported excel file will be saved directly to the server without opening the file.

Avoid Symbol ' In The URL
how to elaborate this problem that i m facing. ok, let say ..i have a URL wit id number such as www.abc.com/memberpage.asp?memberid=12.

when i add the symbol ' at the end of the url (like that:www.abc.com/memberpage.asp?memberid=12'), and enter, it will display error for my page.

But when i try to put a ' at this web page here, it will not display any error, how can i do this with ASP languagE?how can i avoid it using ASP language ?

Avoid Explorer
I'm getting crazy with this. You know that when you install office in your computer it install a plugin for Internet Explorer so when you click in a link to any office document it opens the document inside the explorer instead of asking to save it as normal files.

Do you know how to make internet explorer ask to save the document with HTML or ASP or Javascript?I know that i can disable this option in Internet Explorer options but i don't want to make people do this.I don't want to zip the file neither.

Avoid The IE Seurity
When I use funtion--CreateObject to create an instance of Msword in the client script,
IE security will prevent my script to create. I would not like to alter the security option. how to resolve this problem?

To Avoid Many If Statement
I want to run a query from input. There are 4 input that are optional for user. So what is the simple and fastest way to do it instead of too many if statement and repeating query. What I've done now semilar like this

id = Request.Form("id")
tittle = Request.Form("tittle")
case = Request.Form("case")
desc = Request.Form("desc")

If id <> "" then
Run Query
Else
If tittle <> "" Then.......i have to insert more if statement..how can I make it more easier?

Redirecting From My Home Page Directly To Mail Server Inbox
I have registered a domain, if i want to check my mail i had provision to go to there web server mail page from there i could login and see my emails,

i have a created home page in ASP there i had login page with username and password,

if i enter the username and password it should straight away take me to the email folder(accessing from my home page rather than going to the their web server login page)....

Avoid Send Twice Same Form
I have sometimes duplicate contents in a comments page because impatient people send the same form twice (they pressing in few seconds the Send button twice) . How can I avoid this?

Avoid The Windows Authentication
how can I avoid the windows authentication screen for viewing a report in Reporting Service.

Avoid Warning Message
I am writing a web app using asp.net 1.1 and C#. This web app is launched in another win32 application and this app needs to pass information to my web app. But this win32 application doesn't support long string(Maximum 255)

I hv to use an intermedia plain file and in my web app,usingScripting.FileSystemObject to open the file and read the information in. Each time when I launch the web page, I got a warning message saying "AnActiveX control on this page might be unsafe to interact with other parts of the page. Do you want to allow this interaction?" Users need to click Yes to proceed.

All applications run in Intranet environment within a corporate network. My question are "Can I avoid this error message?" and "Can I give permission to my particular web app to run Scripting.FileSystemObject?"

Avoid Caching Of Page
I am running IIS5.1. I am invoking an ASP page in ther server continously from the HTML Page, to update some contents of the html page. The ASP page seem to run from the cache sometimes(Not Always). I tried to give the following header to my ASP file.

Response.Expires = 0
Response.AddHeader "pragma","no-cache"
Response.AddHeader "cache-control","private"
Response.CacheControl = "no-cache"

still the contents seem to get cached. how can i avoid this ?

Avoid Action Page Being Refresh
Currently i did 2 pages
form and action pages, where form will have 2 inputs, and action page will insert the data into database.

but the i have tested once i keep refresh the action page, the data will be inserted again and again, anyone know how can i control this matter and avoid sql injection?

My Own Webserver
i already setup my own webserver running under win xp prof.. i know that it can only accomodate 10 people at a time.. my questions are the following
1. what OS should i use to accomodate 200 to 500 people at the same time?
2. what should i use MsSql or MYSql?
3. What firewall, virus protection softwares should i use?

New Webserver
Just moved my old webpages to another webserver and now I get this error.

Microsoft OLE DB Provider for ODBC Driverserror '80040e14'

[Microsoft][ODBC Microsoft Access Driver] Unknown /skema/skemaunderviser.asp, line 79

Code around line 79
----------------
set rsSidstOpdateret = server.createobject("adodb.recordset")
set rsWeek = server.createobject("adodb.recordset")
SQLSidstOpdateret = "SELECT * FROM TblDagsDato"
rsSidstOpdateret.open SQLSidstOpdateret, conn, 1,1
SQLGetWeek = "SELECT * FROM TblUger ORDER BY STARTDATO"
rsWeek.open SQLGetWeek, conn, 3,3 (LINE 79)

Validating User Input To Avoid Attacks
I am working on a web application that uses both asp classic and asp.net
pages. We need to validate user input to avoid attacks like sql injection.
Can a component be created that both page types can use? Is that the best
approach? Would I simply use pattern matching to validate strings and/or
remove any unwanted characters?

Avoid Form Resubmission When REFRESH Clicked
I am working with website in which a user can login and then submit some forms. I want the user to avoid re-submitting the same form twice when he uses the browser refresh or when he goes to another page and then comes back to that same page using the browser back button.

I know of two solutions:

1. Redirect to a different page after form submission - The problem with this approach is that the website has many forms. So redirecting each form to a different one is not a very feasible solution.

2. A token can be stored in session (or somewhere) after each form submission. These tokens can be verified if the form is being resubmitted - The problem with this approach is that the user can submit

one form only once. I want the user to be able to submit the same form multiple times, provided with differetn data.

Is there a suitable solution where a form with same data is submitted only once, but there is no such restriction with different data?

Can the ASP request object be cleared after form submission, so even when refresh button is pressed, Request.Form elements dont have any data? (Storing ALL the information filled in each form during that session and then comparing for resubmit is not a clean solution I think??).

Finding The Webserver Name
I need to create a new application in our test server. I am using VID for
that purpose. In order to set up the project in VID, it asks me 'which server
you want to use'. However, I do not have the name of the test server. Is
there any way to configure the name of the server here? I have full rights to
the server directory and is mapped on my machine as G drive.

Secondary Webserver
Is it possible to create a script that can check the availability of an ip address of the primary site and then redirect it according to its conditions?

Setting My Webserver
I've just developed an asp.net website with SQL Server 2000 database. I wish to host it on my own pc. My computer specs are:

AMD 64 3500+
1G DDR RAM
250G HDD 18MB Buffer
ASUS A8V Delux MB
Windows 2003

I was going to install IIS as webserver.what other software do i need and what else i have to set? for sure i have to buy a domain name and redirect it to my ip address.

Webserver Services
I know I have seen a script on here before that would tell what services are installed on a webserver. We have a an old form that sends via CDONTS and the new webserver is running 2003.

I know they could install the CDONTS but it takes them too long to get back to us and I'm sure they wouldn't want to install it. Could some one possibly point me out to the script so I can find out what to use to send the form?

SELECT Statement Pulls Field Names - How To Avoid?
I do a SELECT * from table command in an ASP page to build a text file
out on our server, but the export is not to allow a field name rows of
records. The first thing I get is a row with all the field names. Why
do these come in if they are not part of the table records? How do I
eliminate this from being produced? Code:

Unable To Contact Webserver
I have IIS. I have interdev. whenever I am trying to contact the server..it shows what I have written in the title.

Excel Have To Be Installed On Webserver To Run With ASP
If i am using ASP to extract data from an excel file, does excel definitely have to be installed on the web server? The file will be located on a separate folder away from the web server.

Updating Access MDB On Webserver
how/if I can update records within a Windows hosted Access MDB file directly as I can on Unix based webhosting systems with phpMyAdmin on MySQL databases.

I have an app written in ASP that uses an MDB, that I am currently testing out and each time I want to update the MDB I need to amend my local copy then re-upload it. how?

Protect Documents And Images On Webserver
Is it a way I can protect my documents and images on a webserver without having direct access to administrate the webserver.

When I make an asp page I protect the information pulised on this page easy. But if I link to some images and pdf files on my site, these are not protected. If a person get the url to this image or file thei can easy download it.

One way to protect these files is to store them in a database, but is there another way to protect them.

Can I for example password protect a folder where I can put all my files and images? Here I mean password protect a folder without having direct access to the webserver.

How To Call A Sun One Webserver Plugin From A Asp Page
How to call a sun one webserver plugin from. I want to call NSAPI SAFs from a asp page.
I need a example that how to call SAFs from a client browser....

ASP/IIS Communicating With A VB Based Executable On The Webserver.
I am test developing an internal webserver, on Windows XP, and IIS 5.1, with
ASP and MySQL.

One specific page is created from user input and database records in
previous pages and presents a page with customised data and a webform. It
then takes input from the form and session variables and passes these to an
vb exe in the the wwwroot using the from

http://localhost/example.exe?testparameters. The vb exe takes the command
line parameter input and does its thing and it all works, but I am aware
this is a very insecure way of doing this and I implemented this only as a
quick workaround so I could test implement it all then refine it for
deployment.

My question is, what is the best way for input to be passed from a web form
to an vb executable for it to do its thing. The exe will eventually
preferably run as a service, or at least all ways be active on the server,
and not starting for every request then ending, as I was hoping to allow for
sorting and queueing of requests passed to the exe, before they are
executed. Code:

ASP Site Wont Work On Webserver
Ive build an asp website which works on my local machine and also works when i upload it to other web spaces, but when i upload to one web hosting space - it doesnt (which also happens to be where the client wants it to be).

There are other asp sites running from that location too - which just puzzles me. Would it be something to do with that i use dsn less connections and the other ones use dsn?

ASP LDAP Query Working On Localhost But Not Webserver
I am using classic asp and making a
connection to LDAP server using SQL code under IIS 5 on my localhost
and it works great. I have a form and form fields that pull from
active directory. Now, once I get the web team to deploy these files
to the webserver where all users will be able to run this app.(this
server is using IIS 6), my form fields show up blank. For the life of
me I cannot see what is wrong or different except the IIS version.
Also, I have gotten the IIS logs and they don't tell me anything.

Uploading Test Asp Page With Sql Server 2000 Onto Webserver
I've been trying to create a test site - The site uses ASP with VBscript and talks to SQL Server 2000. I was able to complete and test it on my locally on my computer using Microsoft’s IIS 5.1. The website communicated fine with the database on the webserver/network server

However, when I tried to save the site from my local computer to the wwwroot folder in the server’s IIS hoping to make the internal site available to everyone here the resulting error comes up when we try to open a page with a recordset connected to the database: -

Our Error: -
Microsoft OLE DB Provider for ODBC Drivers (0x80040E4D)
[Microsoft][ODBC SQL Server Driver][SQL Server]Login failed for user 'AUMBSDDSSIUSR_AUMBCOMP'.
/mysite/htm/test2.asp, line 8

The page calls on an include file

Code: ....

Downloading PWS
I have a problem and it's pretty basic. I need to install PWS on a Windows NT Workstation 4.0 PC in college but cannot find a download just for PWS. I've done a search of the web and microsoft's download site and still no luck.

Installing IIS is not an option as Im technically not allowed to install anything and I'd rather it be PWS than a bigger and more noticeable IIS. I've heard that it comes on the Windows 98 disk but unfortuneatly I do not access to one.

Does anyone know of a link to download PWS? I've heard that it comes with an NT Option Pack aswell but can I just install PWS from this or will it change other settings?


Copyright © 2005-08 www.BigResource.com, All rights reserved