After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 113221 - Allow some hosts to not use the proxy
Allow some hosts to not use the proxy
Status: RESOLVED FIXED
Product: galeon
Classification: Deprecated
Component: Mozilla interaction
1.3.4
Other Linux
: Normal normal
: ---
Assigned To: Philip Langdale
Yanko Kaneti
Depends on: 112979
Blocks: 113219
 
 
Reported: 2003-05-18 13:04 UTC by Malcolm Tredinnick
Modified: 2004-12-22 21:47 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch to allow proxy-ignorable hosts. (3.05 KB, patch)
2003-05-18 13:04 UTC, Malcolm Tredinnick
none Details | Review
Fine-tuning the previous patch (3.63 KB, patch)
2003-05-19 02:26 UTC, Malcolm Tredinnick
none Details | Review

Description Malcolm Tredinnick 2003-05-18 13:04:03 UTC
As part of bug #112979, a new key is going to be added to gconf
(/system/http_proxy/ignore_hosts). This key is a list of strings containing
hostnames and IP addresses that should be connected to directly, rather
than via the specified proxy. By default, the key will contain localhost
and 127.0.0.0/8.

The patch attached to this bug report allows Galeon to process this key and
pass it to gtkmozembed for retrieving web pages.

The simplest way to test this patch is to run:

gconftool-2 --type=list --list-type=string --set
/system/http_proxy/ignore_hosts [localhost,127.0.0.0/8]

(all on one line), configure a web browser to talk to a proxy and then
browser http://localhost/ from a machine that is not the proxy. Without the
patch, this browsing will not work. With the patch, it correctly connects
directly to the local machine.

Note that the patch that is coming in the #112979 will correctly handle
IPv6 addresses as well and things are stored in the same format that
mozilla expects them, so IPv4 and IPv6 will both work transparently.
Comment 1 Malcolm Tredinnick 2003-05-18 13:04:52 UTC
Created attachment 16605 [details] [review]
Patch to allow proxy-ignorable hosts.
Comment 2 Philip Langdale 2003-05-18 14:31:32 UTC
Patch applied to cvs. Many thanks, Malcolm!
Comment 3 Malcolm Tredinnick 2003-05-18 23:58:19 UTC
OK, that was amusing: I filed essentially the same bug against
epiphany and those guys pointed out two problems with the patch
(nothing major; we haven't broken Galeon or anything like that). You
might want to have a read of the comments in bug #113222. Exactly the
same comments apply to the galeon version: when the list is empty, it
is not reset in mozilla and there is already a secret gconf key for
ignoring certain hosts, which now becomes deprecated.

Fixing the empty list part is easy; I will submit another patch to do
that. How to handle the deprecated gconf key (and it should be
deprecated so that all of GNOME uses the same key) is something you
will need to make a call on Philip. I have given a couple of
possibilities in #113222.
Comment 4 Philip Langdale 2003-05-19 01:28:06 UTC
The old local no_proxy gconf entry does not really need to be worried
about. It is not actually respected by the code (one has to ask why)
so I don't see any need to provide backward compatibility for it.

I await your confirmation that taking out the null check will result
in the desired behaviour.
Comment 5 Malcolm Tredinnick 2003-05-19 02:26:58 UTC
Created attachment 16614 [details] [review]
Fine-tuning the previous patch
Comment 6 Malcolm Tredinnick 2003-05-19 02:29:35 UTC
This new patch fixes the case when the gconf key is empty or missing
-- in both cases mozilla is correctly informed of the value.

It also removes the older gconf key and corrects the schema file. I
think this key was being used, Philip, but since it was already in the
format mozilla expected (a comma-separated string), it was just
trivially mapped to a mozilla preference. I don't think removing this
old key should cause too much trauma, but I will leave it up to you.
Comment 7 Philip Langdale 2003-05-19 04:02:17 UTC
Updated patch applied. Thanks. Trying to close again :-)