473,403 Members | 2,366 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,403 software developers and data experts.

Redirect to a file on the server (not in wwwroot)

Hi all,

I want to do a similar action to response.redirect ("file.htm"). But the
file.htm contains some sensitive data. I have placed file.htm in a folder in
the InetPub (d:\inetpub\privateroot\file.htm) so that it is not accessible
by a simple HTTP request. An asp login script will be used, and then once
the user is verified the page should redirect to
d:\inetpub\privateroot\file.htm. But obviously I cannot use
response.redirect because it is not a recognisable URL. Any ideas which
command I should use?

Btw, I use VB Script.
_________________________
<%= TIM_STOKES %>
(change the _'s in my e-mail address to .'s (this is anti-spam))

Jul 19 '05 #1
6 4430
Can't be done. A browser can not access a page that is not
part of a web site. (Tehcnically, that's not 100% true,
but it applies in your case)

You must either place the page in a directory accessible
via the web or create a virtual directory on the directory
where your file lives.

NOTE: If you are on an intranet and the directory where
your file lives is on an accessible share, you could link
to it, but you still won't be able to use
response.redirect.

John
-----Original Message-----
Hi all,

I want to do a similar action to response.redirect ("file.htm"). But thefile.htm contains some sensitive data. I have placed file.htm in a folder inthe InetPub (d:\inetpub\privateroot\file.htm) so that it is not accessibleby a simple HTTP request. An asp login script will be used, and then oncethe user is verified the page should redirect to
d:\inetpub\privateroot\file.htm. But obviously I cannot useresponse.redirect because it is not a recognisable URL. Any ideas whichcommand I should use?

Btw, I use VB Script.
_________________________
<%= TIM_STOKES %>
(change the _'s in my e-mail address to .'s (this is anti- spam))
.

Jul 19 '05 #2
Ok, cheers.

Do you have any suggestions as to how can I secure file.htm from being
retrieved without having put the username or password in??
_________________________
<%= TIM_STOKES %>
(change the _'s in my e-mail address to .'s (this is anti-spam))
"John Beschler" <gi***@geewhiz.com> wrote in message
news:0b****************************@phx.gbl...
Can't be done. A browser can not access a page that is not
part of a web site. (Tehcnically, that's not 100% true,
but it applies in your case)

You must either place the page in a directory accessible
via the web or create a virtual directory on the directory
where your file lives.

NOTE: If you are on an intranet and the directory where
your file lives is on an accessible share, you could link
to it, but you still won't be able to use
response.redirect.

John
-----Original Message-----
Hi all,

I want to do a similar action to response.redirect

("file.htm"). But the
file.htm contains some sensitive data. I have placed

file.htm in a folder in
the InetPub (d:\inetpub\privateroot\file.htm) so that it

is not accessible
by a simple HTTP request. An asp login script will be

used, and then once
the user is verified the page should redirect to
d:\inetpub\privateroot\file.htm. But obviously I cannot

use
response.redirect because it is not a recognisable URL.

Any ideas which
command I should use?

Btw, I use VB Script.
_________________________
<%= TIM_STOKES %>
(change the _'s in my e-mail address to .'s (this is anti-

spam))

.

Jul 19 '05 #3
Ah yeah,

Thought I'd mention that it's a remotly hosted site and I cannot use NT
security etc...
_________________________
<%= TIM_STOKES %>
(change the _'s in my e-mail address to .'s (this is anti-spam))
"Tim Stokes" <tim.stokes@freshfmmanchester_co_uk> wrote in message
news:3f**********@mk-nntp-2.news.uk.tiscali.com...
Ok, cheers.

Do you have any suggestions as to how can I secure file.htm from being
retrieved without having put the username or password in??
_________________________
<%= TIM_STOKES %>
(change the _'s in my e-mail address to .'s (this is anti-spam))
"John Beschler" <gi***@geewhiz.com> wrote in message
news:0b****************************@phx.gbl...
Can't be done. A browser can not access a page that is not
part of a web site. (Tehcnically, that's not 100% true,
but it applies in your case)

You must either place the page in a directory accessible
via the web or create a virtual directory on the directory
where your file lives.

NOTE: If you are on an intranet and the directory where
your file lives is on an accessible share, you could link
to it, but you still won't be able to use
response.redirect.

John
-----Original Message-----
Hi all,

I want to do a similar action to response.redirect

("file.htm"). But the
file.htm contains some sensitive data. I have placed

file.htm in a folder in
the InetPub (d:\inetpub\privateroot\file.htm) so that it

is not accessible
by a simple HTTP request. An asp login script will be

used, and then once
the user is verified the page should redirect to
d:\inetpub\privateroot\file.htm. But obviously I cannot

use
response.redirect because it is not a recognisable URL.

Any ideas which
command I should use?

Btw, I use VB Script.
_________________________
<%= TIM_STOKES %>
(change the _'s in my e-mail address to .'s (this is anti-

spam))

.


Jul 19 '05 #4
If it's an ASP file, then include as the first part of the
file a check for some session variable. If the session
variable is NOT what you think it should be, then redirect
the visitor to a page which requires a login and password.

For example:

In the "secure" page:
If Session("Authorised") <> "True" Then
Response.redirect("Login.asp")
End If

In login.asp:
If ValidUser = True Then
Session("Authorised") = "True"
Else
Session("Authorised") = "False"
End If

This way anytime the page is requested, the first thing it
will do is verify the user has met your credentials.

If your page is HTML, simply change the Extension to .ASP
and add the code at the begining as above.

We use this at: www.stagecrafters.com/admin and it works
quite well.

-----Original Message-----
Ok, cheers.

Do you have any suggestions as to how can I secure file.htm from beingretrieved without having put the username or password in??
_________________________
<%= TIM_STOKES %>
(change the _'s in my e-mail address to .'s (this is anti- spam))

"John Beschler" <gi***@geewhiz.com> wrote in message
news:0b****************************@phx.gbl...
Can't be done. A browser can not access a page that is not part of a web site. (Tehcnically, that's not 100% true,
but it applies in your case)

You must either place the page in a directory accessible
via the web or create a virtual directory on the directory where your file lives.

NOTE: If you are on an intranet and the directory where
your file lives is on an accessible share, you could link to it, but you still won't be able to use
response.redirect.

John
>-----Original Message-----
>Hi all,
>
>I want to do a similar action to response.redirect

("file.htm"). But the
>file.htm contains some sensitive data. I have placed

file.htm in a folder in
>the InetPub (d:\inetpub\privateroot\file.htm) so that
it is not accessible
>by a simple HTTP request. An asp login script will be

used, and then once
>the user is verified the page should redirect to
>d:\inetpub\privateroot\file.htm. But obviously I cannot

use
>response.redirect because it is not a recognisable URL.

Any ideas which
>command I should use?
>
>Btw, I use VB Script.
>_________________________
><%= TIM_STOKES %>
>(change the _'s in my e-mail address to .'s (this is
anti- spam))
>
>
>
>.
>

.

Jul 19 '05 #5
Does anyone have a suggestion as to how I could automate this function?

Cheers
_________________________
<%= TIM_STOKES %>
(change the _'s in my e-mail address to .'s (this is anti-spam))
"Tim Stokes" <tim.stokes@freshfmmanchester_co_uk> wrote in message
news:3f********@mk-nntp-2.news.uk.tiscali.com...
Thanks

That would have been my next idea... it's just that there are going to be
about 500+ html pages added per day!
_________________________
<%= TIM_STOKES %>
(change the _'s in my e-mail address to .'s (this is anti-spam))
"John Beschler" <gi***@geewhiz.com> wrote in message
news:6c****************************@phx.gbl...
If it's an ASP file, then include as the first part of the
file a check for some session variable. If the session
variable is NOT what you think it should be, then redirect
the visitor to a page which requires a login and password.

For example:

In the "secure" page:
If Session("Authorised") <> "True" Then
Response.redirect("Login.asp")
End If

In login.asp:
If ValidUser = True Then
Session("Authorised") = "True"
Else
Session("Authorised") = "False"
End If

This way anytime the page is requested, the first thing it
will do is verify the user has met your credentials.

If your page is HTML, simply change the Extension to .ASP
and add the code at the begining as above.

We use this at: www.stagecrafters.com/admin and it works
quite well.

-----Original Message-----
Ok, cheers.

Do you have any suggestions as to how can I secure

file.htm from being
retrieved without having put the username or password in??
_________________________
<%= TIM_STOKES %>
(change the _'s in my e-mail address to .'s (this is anti-

spam))


"John Beschler" <gi***@geewhiz.com> wrote in message
news:0b****************************@phx.gbl...
> Can't be done. A browser can not access a page that is

not
> part of a web site. (Tehcnically, that's not 100% true,
> but it applies in your case)
>
> You must either place the page in a directory accessible
> via the web or create a virtual directory on the

directory
> where your file lives.
>
> NOTE: If you are on an intranet and the directory where
> your file lives is on an accessible share, you could

link
> to it, but you still won't be able to use
> response.redirect.
>
> John
>
>
>
> >-----Original Message-----
> >Hi all,
> >
> >I want to do a similar action to response.redirect
> ("file.htm"). But the
> >file.htm contains some sensitive data. I have placed
> file.htm in a folder in
> >the InetPub (d:\inetpub\privateroot\file.htm) so that

it
> is not accessible
> >by a simple HTTP request. An asp login script will be
> used, and then once
> >the user is verified the page should redirect to
> >d:\inetpub\privateroot\file.htm. But obviously I cannot
> use
> >response.redirect because it is not a recognisable URL.
> Any ideas which
> >command I should use?
> >
> >Btw, I use VB Script.
> >_________________________
> ><%= TIM_STOKES %>
> >(change the _'s in my e-mail address to .'s (this is

anti-
> spam))
> >
> >
> >
> >.
> >
.


Jul 19 '05 #6
There are aliases... And there are password protaced dirs... And you can
open the file, then output it...

With my setup, there are lots of ways to do it as I must request everything
through my Apache which can password protect stuff, and I can use a perl,
php or jsp script to verify the user, then send an internal request to
Apache which forwards that request to the private IIS dir, then the Apache
script would get the output of the IIS script, then it could output it to
the user... Although, I doubt very many ppl have this wierd setup so the
first paragraph would most likely be most worth reading...

--
// DvDmanDT
MSN: dv******@hotmail.com
Mail: dv******@telia.com
"Tim Stokes" <tim.stokes@freshfmmanchester_co_uk> skrev i meddelandet
news:3f********@mk-nntp-2.news.uk.tiscali.com...
Does anyone have a suggestion as to how I could automate this function?

Cheers
_________________________
<%= TIM_STOKES %>
(change the _'s in my e-mail address to .'s (this is anti-spam))
"Tim Stokes" <tim.stokes@freshfmmanchester_co_uk> wrote in message
news:3f********@mk-nntp-2.news.uk.tiscali.com...
Thanks

That would have been my next idea... it's just that there are going to be about 500+ html pages added per day!
_________________________
<%= TIM_STOKES %>
(change the _'s in my e-mail address to .'s (this is anti-spam))
"John Beschler" <gi***@geewhiz.com> wrote in message
news:6c****************************@phx.gbl...
If it's an ASP file, then include as the first part of the
file a check for some session variable. If the session
variable is NOT what you think it should be, then redirect
the visitor to a page which requires a login and password.

For example:

In the "secure" page:
If Session("Authorised") <> "True" Then
Response.redirect("Login.asp")
End If

In login.asp:
If ValidUser = True Then
Session("Authorised") = "True"
Else
Session("Authorised") = "False"
End If

This way anytime the page is requested, the first thing it
will do is verify the user has met your credentials.

If your page is HTML, simply change the Extension to .ASP
and add the code at the begining as above.

We use this at: www.stagecrafters.com/admin and it works
quite well.


>-----Original Message-----
>Ok, cheers.
>
>Do you have any suggestions as to how can I secure
file.htm from being
>retrieved without having put the username or password in??
>_________________________
><%= TIM_STOKES %>
>(change the _'s in my e-mail address to .'s (this is anti-
spam))
>
>
>"John Beschler" <gi***@geewhiz.com> wrote in message
>news:0b****************************@phx.gbl...
>> Can't be done. A browser can not access a page that is
not
>> part of a web site. (Tehcnically, that's not 100% true,
>> but it applies in your case)
>>
>> You must either place the page in a directory accessible
>> via the web or create a virtual directory on the
directory
>> where your file lives.
>>
>> NOTE: If you are on an intranet and the directory where
>> your file lives is on an accessible share, you could
link
>> to it, but you still won't be able to use
>> response.redirect.
>>
>> John
>>
>>
>>
>> >-----Original Message-----
>> >Hi all,
>> >
>> >I want to do a similar action to response.redirect
>> ("file.htm"). But the
>> >file.htm contains some sensitive data. I have placed
>> file.htm in a folder in
>> >the InetPub (d:\inetpub\privateroot\file.htm) so that
it
>> is not accessible
>> >by a simple HTTP request. An asp login script will be
>> used, and then once
>> >the user is verified the page should redirect to
>> >d:\inetpub\privateroot\file.htm. But obviously I cannot
>> use
>> >response.redirect because it is not a recognisable URL.
>> Any ideas which
>> >command I should use?
>> >
>> >Btw, I use VB Script.
>> >_________________________
>> ><%= TIM_STOKES %>
>> >(change the _'s in my e-mail address to .'s (this is
anti-
>> spam))
>> >
>> >
>> >
>> >.
>> >
>
>
>.
>



Jul 19 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Jon Maz | last post by:
Hi All, To allow myself to make development changes directly on a remote server *without* having to compile on my local dev machine and then upload the dll's to remote, I have created a...
4
by: Philippe Meunier | last post by:
Hello, I've built a web application that ask the user for 3 values (textboxes) and when the user press a button (command button) the server genereates a report in a temporary html file My App...
5
by: john | last post by:
Hello, One our thrid page for some reason the response.redirect isn't working on the live server. It works fine on the development machine but when we move the code to the live server it doesn't...
2
by: WJ | last post by:
1. I have a website called "myWeb" resides under E:\SOS\myWeb.Net" folder in an IIS-6/Windows 2003 server. Its host-header is "myWeb.Net". 2. Default page is "Index.aspx". 3. In the same...
7
by: Mark | last post by:
Hello, I have researched and tried every thing I have found on the web, in groups and MS KB articles. Here is what I have. I have a Windows 2000 Domain Controller all service packs and...
4
by: news.microsoft.com | last post by:
Hello All, im am new to ASP.NET, so bare with me. i have an application that i am building in stages. stage1 user picks data required stage2 file is written to a virutal directory Stage3...
1
by: ddelaney | last post by:
I've seen this posted before in many places, but have yet to find a real fix. I have a web application on dev server right now, and randomly, hours or days, it returns the expception posted below. ...
9
by: KenLee | last post by:
I made an application which includes classic asp page and asp.net page. when I tried to redirect from classic asp page to asp.net 2.0 page, it works under my local IIS directory. ex) <a...
1
by: Craig Douglas | last post by:
Hi, I have a problem with getting a redirect to work on our server. It's worked fine on our server for months, but suddenly won't work and I can't figure out why. codewise, It's nothing...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.