Mailing List Archive

Does the standard ftplib module support proxies?
The header says it all... I've looked in the manual, but I can't see
anything about proxy (firewall) support, one way or another.

Actually, the same question applies to httplib and urllib.

Thanks,
Paul Moore.
Does the standard ftplib module support proxies? [ In reply to ]
Paul Moore wrote:
>
> The header says it all... I've looked in the manual, but I can't see
> anything about proxy (firewall) support, one way or another.
>
> Actually, the same question applies to httplib and urllib.
>
> Thanks,
> Paul Moore.

It depends on what kind of proxy.
I've found it works fine if the proxy is the nice simple kind
that lets you connect to the proxy host on FTP port 21 and specify
the remote ftp location using the form user@site.
I haven't tried to make it work with any other kind (and there
are quite a few).


--
Dale Nagata | tel : +1 604.451.2700 ext. 2254 (UTC-0800)
Software Developer | fax : +1 604.437.9891
Creo Products Inc. | pgr : +1 604.691.8279
Burnaby BC Canada | http://www.creo.com/
Does the standard ftplib module support proxies? [ In reply to ]
The standard urllib.py also supports proxies. I don't think the library =
manual explains it, and I found the internal docs insufficient. Search =
dejanews for urllib and proxy to find some help.

Basically, you set an environment variable that defines the proxy:
(NT example)
SET http_proxy=3Dhttp://204.71.200.68:8080
and urllib takes it from there.

For me it works on a standard proxy, but not with a socks server

This is just from my [recent] experience with a new firewall that was =
imposed on me. I'm not an expert on the subject. I hope the urllib =
documentation can be improved in this area. Maybe a python/firewall HOWTO =
is in order?

--Jeff

>>> Paul Moore <gustav@morpheus.demon.co.uk> 04/11/99 04:26pm >>>
The header says it all... I've looked in the manual, but I can't see
anything about proxy (firewall) support, one way or another.

Actually, the same question applies to httplib and urllib.

Thanks,
Paul Moore.