Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

login to ftp from a web link

1 view
Skip to first unread message

sb

unread,
Oct 4, 2003, 2:23:18 AM10/4/03
to
Ok, this has got to be a common problem...
I want to have a page with some files listed as links to the files actually
located on a remote(unix) server (different one to my IIS). In ASP I
dynamically build the url to be:

ftp://username:password@servername/dir1/dir2/filename.gz

...other than it displays the username/password, this should work (the
username/password can be hidden by having it redirect to another page).
Problem is I get a DNS error on the first attempt. The wierd thing is that
if I type this url into the Address bar of my browser it firstly gives me
the dns error and then on the second time works!

My theory of what is happening is that the first time through it logged into
the ftp server, then the second time it logs straight in without the need
for the password. Has anyone had the same problem and found a fix?

I assume this is some kind of security block, but it is kind of annoing
given how easy it would be to implement ftp ability to web sites with no
code on the client.

I am using IIS5 and ASP and vbscript.

Please reply to this newsgroup as my email is a dummy.

SB


Ray at <%=sLocation%>

unread,
Oct 4, 2003, 2:35:33 AM10/4/03
to
It's probably because you're linking to a filename instead of the directory
containing the filename.

If the remote server will support it, you could setup a virtual directory in
IIS that goes to \\otherserver\share and store your username and password
within IIS for the virtual directory.

Ray at home

"sb" <s...@hotmail.com> wrote in message
news:bllp0p$n66$1...@otis.netspace.net.au...

sb

unread,
Oct 4, 2003, 2:37:21 AM10/4/03
to
Thanks Ray but I can't use virtual directories in my case.
SB

"Ray at <%=sLocation%>" <myfirstname at lane 34 . komm> wrote in message
news:OHDk4Eki...@TK2MSFTNGP11.phx.gbl...

Ray at <%=sLocation%>

unread,
Oct 4, 2003, 2:44:29 AM10/4/03
to
Alright, then remove the filename from your path. You'll notice that if you
copy and paste that link into your browser, it won't work. You have to
browse to the directory with the file, not to the file itself. I don't
think there's any automatic GET command sent if you browse to a file.

Ray at home

"sb" <s...@hotmail.com> wrote in message

news:bllpr8$ncj$1...@otis.netspace.net.au...

sb

unread,
Oct 4, 2003, 3:05:46 AM10/4/03
to
Let me put it another way.
This works:
ftp://ftp.microsoft.com/Softlib/MSLFILES/TBKNET.EXE

...however if it was not anonymous, then this would be required...
ftp://auser:pas...@ftp.microsoft.com/Softlib/MSLFILES/TBKNET.EXE

...this does not work the first time. But the second time it does!

SB

"Ray at <%=sLocation%>" <myfirstname at lane 34 . komm> wrote in message

news:u0ky3Jki...@tk2msftngp13.phx.gbl...

Ray at <%=sLocation%>

unread,
Oct 4, 2003, 4:53:09 AM10/4/03
to
What happens? Do you get a prompt to download the exe? Does it run? In my
browse, IE6, if I enter an ftp path to a file, that does not work, auth or
anon.

Ray at home

"sb" <s...@hotmail.com> wrote in message

news:bllrgf$nq3$1...@otis.netspace.net.au...

sb

unread,
Oct 7, 2003, 7:50:49 AM10/7/03
to
Yes a prompt to download the file appears.
SB

"Ray at <%=sLocation%>" <myfirstname at lane 34 . komm> wrote in message

news:uKAXxRli...@TK2MSFTNGP11.phx.gbl...

0 new messages