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 595690 - entering 'localhost:8000' does a google search
entering 'localhost:8000' does a google search
Status: RESOLVED FIXED
Product: epiphany
Classification: Core
Component: Backend
2.27.x
Other Linux
: Normal normal
: ---
Assigned To: Gustavo Noronha (kov)
Epiphany Maintainers
: 597807 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2009-09-19 17:10 UTC by Sam Morris
Modified: 2009-11-10 17:12 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
this patch should fix all of the problems mentioned here (1.07 KB, patch)
2009-10-04 11:35 UTC, Gustavo Noronha (kov)
none Details | Review

Description Sam Morris 2009-09-19 17:10:38 UTC
When I enter 'localhost:8000' into the address entry with epiphany/webkit, a google search is performed instead of epiphany trying to connect to the URL.
Comment 1 Jorge Kalmbach 2009-09-24 02:08:43 UTC
Can't reproduce this on epiphany 2.27.91 - webkit - linux.
Comment 2 Sam Morris 2009-09-27 10:05:13 UTC
Happens for me with 2.28.0. Also occurs if I type 'localhost/manual' instead of 'http://localhost/manual'.
Comment 3 Reinout van Schouwen 2009-09-27 19:43:00 UTC
I can reproduce the problem. Jorge, have you tried with or without http:// in front or the URL?
Comment 4 Jorge Kalmbach 2009-09-29 16:24:03 UTC
i'm back, just installed epy 2.28

with http://localhost:8000 I get (i don't have a http server installed)
---------------------------------------------------------------
Unable to load page
Problem occurred while loading the URL http://localhost:8080/
Cannot connect to destination
[Try Again]
---------------------------------------------------------------

with localhost:8000, I get redirected to google.
So, I correct my self, I can reproduce the bug. confirmed.
Comment 5 Gustavo Noronha (kov) 2009-10-04 11:35:34 UTC
Created attachment 144705 [details] [review]
this patch should fix all of the problems mentioned here
Comment 6 Xan Lopez 2009-10-06 06:40:57 UTC
(In reply to comment #5)
> Created an attachment (id=144705) [details]
> this patch should fix all of the problems mentioned here

OK, please commit.

Did you get to see what Gecko uses to figure this out? Whatever it is I'd like to use their solution which probably has quite a few million-man hours in testing at this point.
Comment 7 Gustavo Noronha (kov) 2009-10-07 10:13:27 UTC
(In reply to comment #6)
> OK, please commit.
> 
> Did you get to see what Gecko uses to figure this out? Whatever it is I'd like
> to use their solution which probably has quite a few million-man hours in
> testing at this point.

Though our regex works best for some stuff =D

But no, I couldn't find it. I will try harder as soon as I have more time, but I'm happy if anyone is able to point me in the right direction at least =(
Comment 8 Gustavo Noronha (kov) 2009-10-07 10:19:11 UTC
Pushed to master, thanks.
Comment 9 Reinout van Schouwen 2009-10-09 09:06:06 UTC
*** Bug 597807 has been marked as a duplicate of this bug. ***
Comment 10 Gerald Butler 2009-11-09 14:06:54 UTC
As of 2.28.1 Epiphany Webkit from the PPA on Ubuntu 9.10 this problem is still not resolved. What release is this fix likely to appear in?
Comment 11 Gustavo Noronha (kov) 2009-11-09 14:44:34 UTC
(In reply to comment #10)
> As of 2.28.1 Epiphany Webkit from the PPA on Ubuntu 9.10 this problem is still
> not resolved. What release is this fix likely to appear in?

The fix should be in 2.28.1, yeah. Have you closed all windows, and started epiphany from scratch after upgrading?
Comment 12 Gerald Butler 2009-11-09 20:12:56 UTC
Yes, I've definitely updated correctly. I've been running 2.28.1 for quite some time now. This is definitely NOT fixed in 2.28.1 (at least not the version that is in the Ubuntu 9.10 PPA).

Anything else I can do to help determine the problem?

This bug also affects "Ubuntu One" on Ubuntu. If you have Epiphany set as default Web Browser (which I do) and then try to use "Ubuntu One" it tries to tell the browser to connect to "http://localhost:<port>..." so that it can register the "Ubuntu One" account. Because "Localhost" is not resolving correctly, I needed to copy the URL from Epiphany Webkit to Firefox to get Ubuntu One to register correctly.

Not many people must be using Epiphany Webkit as their default browser on Ubuntu 9.10 (understandably so as it is not installed by default).

Anyway, I've always been a big fan of Galeon/Epiphany. Keep up the good work.

If there is anything else I can provide to help resolve this issue, please let me know.
Comment 13 Xan Lopez 2009-11-09 20:27:11 UTC
Does it work if you use 127.0.0.1 instead of 'localhost'?
Comment 14 Gustavo Noronha (kov) 2009-11-09 21:18:37 UTC
(In reply to comment #12)
> This bug also affects "Ubuntu One" on Ubuntu. If you have Epiphany set as
> default Web Browser (which I do) and then try to use "Ubuntu One" it tries to
> tell the browser to connect to "http://localhost:<port>..." so that it can
> register the "Ubuntu One" account. Because "Localhost" is not resolving
> correctly, I needed to copy the URL from Epiphany Webkit to Firefox to get
> Ubuntu One to register correctly.

This is funny. Can you give me the complete URL so that I can test it?

> Anyway, I've always been a big fan of Galeon/Epiphany. Keep up the good work.

Me too =)
Comment 15 Gerald Butler 2009-11-09 21:48:29 UTC
Yes, If I change the URL to use 127.0.0.1 instead of localhost it works correctly. Here is the URL "Ubuntu One" tries to use: .... oops, sorry.....

I can't get "Ubuntu One" to try the register again now that I've successfully registered it. It does however work if you change to 127.0.0.1. I've had to re-register my machine several times as they've gone through iterations of "Ubuntu One". I've gotten it to successfully register by changing "localhost" to "127.0.0.1" in the URL bar, and I've gottent successful registration by copying the URL from the URL bar of Epiphany into Firefox without changing "localhost" to "127.0.0.1".

BTW, I have the following PPA's enabled in order to have Epiphany 2.28.1:

    http://ppa.launchpad.net/webkit-team/epiphany/ubuntu karmic main
    http://ppa.launchpad.net/webkit-team/ppa/ubuntu karmic main

This is correct, no?
Comment 16 Gerald Butler 2009-11-09 21:50:53 UTC
Another point of interest: I have the following "Extensions" enabled:

Actions
Ad Blocker
Certificates
GreaseMonkey
News Feed Subscription
Permissions
SOUP Fly
Tab Groups

Might any of these be causing an issue? Should I try disabling any/all of them?
Comment 17 Gerald Butler 2009-11-09 21:53:56 UTC
Well, I just tried disabling all of the above extensions. Didn't seem to make any difference. Should I try uninstalling the extensions? Would that matter?
Comment 18 Gerald Butler 2009-11-09 22:01:00 UTC
Nope, uninstalling ALL the extensions didn't help either. Also tried disabling "Web Inspector" from the preferences - didn't help either.
Comment 19 Gerald Butler 2009-11-09 22:12:43 UTC
Just upgraded to 2.29.1 from the Ubuntu 9.10 (Karmic) PPA and still have the same issue resolving "localhost" addresses. Doesn't work at all with "localhost" must change to "127.0.0.1" to have it work.
Comment 20 Gerald Butler 2009-11-09 22:16:03 UTC
Just upgraded to 2.29.1 from the Ubuntu 9.10 (Karmic) PPA and still have the same issue resolving "localhost" addresses. Doesn't work at all with "localhost" must change to "127.0.0.1" to have it work.
Comment 21 Gerald Butler 2009-11-09 22:30:55 UTC
To clarify, any of the following will not work:

"localhost"
"localhost/somepath"
"locahost:someport/somepath"
"http://localhost"
"http://locahost/somepath"
"http://localhost:someport/somepath"

However, any of these do work:

"127.0.0.1"
"127.0.0.1/somepath"
"127.0.0.1:someport/somepath"
"http://127.0.0.1"
"http://127.0.0.1/somepath"
"http://127.0.0.0:someport/somepath"

where "someport" is any valid port number and "somepath" is a valid path on the WebServer listening on that port.
Comment 22 Gustavo Noronha (kov) 2009-11-09 22:38:21 UTC
(In reply to comment #21)
> To clarify, any of the following will not work:
> 
> "localhost"
> "localhost/somepath"
> "locahost:someport/somepath"
> "http://localhost"
> "http://locahost/somepath"
> "http://localhost:someport/somepath"
> 
> However, any of these do work:

Let me just clarify this: is the problem you are having that a search is being done in google with those as search queries, or is it that you get a page saying that it was not able to connect to the destination? 

Can you also please post the contents of your /etc/hosts, and try 'ping localhost', and 'ping localhost.localdomain' on a terminal?
Comment 23 Xan Lopez 2009-11-10 07:10:01 UTC
(In reply to comment #15)
> Yes, If I change the URL to use 127.0.0.1 instead of localhost it works
> correctly. Here is the URL "Ubuntu One" tries to use: .... oops, sorry.....
> 
> I can't get "Ubuntu One" to try the register again now that I've successfully
> registered it. It does however work if you change to 127.0.0.1. I've had to
> re-register my machine several times as they've gone through iterations of
> "Ubuntu One". I've gotten it to successfully register by changing "localhost"
> to "127.0.0.1" in the URL bar, and I've gottent successful registration by
> copying the URL from the URL bar of Epiphany into Firefox without changing
> "localhost" to "127.0.0.1".
> 
> BTW, I have the following PPA's enabled in order to have Epiphany 2.28.1:
> 
>     http://ppa.launchpad.net/webkit-team/epiphany/ubuntu karmic main
>     http://ppa.launchpad.net/webkit-team/ppa/ubuntu karmic main
> 
> This is correct, no?

This is an specific debian/ubuntu problem, AFAIK. You have both the ipv4 and ipv6 local addresses pointing to localhost, and debian/ubuntu is returning the ipv6 one first, IIRC, and libsoup is getting all confused about this. Just edit /etc/hosts and remove the ipv6 one.

I believe danw says he'll eventually get to do some workaround for this in libsoup.
Comment 24 Gerald Butler 2009-11-10 13:35:38 UTC
(In reply to comment #23)
> (In reply to comment #15)
> > Yes, If I change the URL to use 127.0.0.1 instead of localhost it works
> > correctly. Here is the URL "Ubuntu One" tries to use: .... oops, sorry.....
> > 
> > I can't get "Ubuntu One" to try the register again now that I've successfully
> > registered it. It does however work if you change to 127.0.0.1. I've had to
> > re-register my machine several times as they've gone through iterations of
> > "Ubuntu One". I've gotten it to successfully register by changing "localhost"
> > to "127.0.0.1" in the URL bar, and I've gottent successful registration by
> > copying the URL from the URL bar of Epiphany into Firefox without changing
> > "localhost" to "127.0.0.1".
> > 
> > BTW, I have the following PPA's enabled in order to have Epiphany 2.28.1:
> > 
> >     http://ppa.launchpad.net/webkit-team/epiphany/ubuntu karmic main
> >     http://ppa.launchpad.net/webkit-team/ppa/ubuntu karmic main
> > 
> > This is correct, no?
> 
> This is an specific debian/ubuntu problem, AFAIK. You have both the ipv4 and
> ipv6 local addresses pointing to localhost, and debian/ubuntu is returning the
> ipv6 one first, IIRC, and libsoup is getting all confused about this. Just edit
> /etc/hosts and remove the ipv6 one.
> 
> I believe danw says he'll eventually get to do some workaround for this in
> libsoup.

You nailed it. Thanks. I edited the /etc/hosts and changed the following line:

127.0.0.1	localhost
127.0.1.1	gbutler-laptop

# The following lines are desirable for IPv6 capable hosts
::1     ip6-localhost ip6-loopback   <<<---- This used to be ::1 localhost ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
ff02::3 ip6-allhosts

That fixed the problem.

Is there another bug ticket that is tracking this issue with respect to lipsoup? Can I offer any assistance in debugging it further and/or creating a patch?

What's the best way to get started?

Thanks again.
Comment 25 Dan Winship 2009-11-10 15:49:25 UTC
the libsoup bug is bug 526321. no debugging assistance is needed, we understand the problem. the trick is just coming up with a workaround that doesn't require rewriting everything. but i'm hoping to have it fixed for 2.28.2
Comment 26 Gerald Butler 2009-11-10 16:13:52 UTC
Wow! Finally, problem solved! I've been having trouble since the upgrade to Ubuntu 9.10 with Epiphany WebKit not resolving "localhost" addresses correctly. Also, web page loading has been unusually slow and I thought it was my network. I just edited /etc/gai.conf and uncommented the lines pre-configured in the default file (including the line to prefer IPv4 over IPv6) and TADA it now works correctly AND FASTER! Yay!(In reply to comment #25)
> the libsoup bug is bug 526321. no debugging assistance is needed, we understand
> the problem. the trick is just coming up with a workaround that doesn't require
> rewriting everything. but i'm hoping to have it fixed for 2.28.2

Wow! Finally, problem solved! I've been having trouble since the upgrade to Ubuntu 9.10 with Epiphany WebKit not resolving "localhost" addresses correctly. Also, web page loading has been unusually slow and I thought it was my network. I just edited /etc/gai.conf and uncommented the lines pre-configured in the default file (including the line to prefer IPv4 over IPv6) and TADA it now works correctly AND FASTER! Yay!
Comment 27 Gerald Butler 2009-11-10 16:15:32 UTC
BTW, I also re-added the "localhost" to the Link Local IPv6 address in /etc/hosts. Once I fixed /etc/gai.conf that was no longer required to be removed. For anyone else interest, please review Bug 526321.


(In reply to comment #26)
> Wow! Finally, problem solved! I've been having trouble since the upgrade to
> Ubuntu 9.10 with Epiphany WebKit not resolving "localhost" addresses correctly.
> Also, web page loading has been unusually slow and I thought it was my network.
> I just edited /etc/gai.conf and uncommented the lines pre-configured in the
> default file (including the line to prefer IPv4 over IPv6) and TADA it now
> works correctly AND FASTER! Yay!(In reply to comment #25)
> > the libsoup bug is bug 526321. no debugging assistance is needed, we understand
> > the problem. the trick is just coming up with a workaround that doesn't require
> > rewriting everything. but i'm hoping to have it fixed for 2.28.2
> 
> Wow! Finally, problem solved! I've been having trouble since the upgrade to
> Ubuntu 9.10 with Epiphany WebKit not resolving "localhost" addresses correctly.
> Also, web page loading has been unusually slow and I thought it was my network.
> I just edited /etc/gai.conf and uncommented the lines pre-configured in the
> default file (including the line to prefer IPv4 over IPv6) and TADA it now
> works correctly AND FASTER! Yay!
Comment 28 Gustavo Noronha (kov) 2009-11-10 17:04:12 UTC
(In reply to comment #27)
> BTW, I also re-added the "localhost" to the Link Local IPv6 address in
> /etc/hosts. Once I fixed /etc/gai.conf that was no longer required to be
> removed. For anyone else interest, please review Bug 526321.

Great =). Just a comment, Xan and I asked the questions we have because we noticed you were not having the same problem as this bug report. Notice that this bug report deals with 'localhost:8000' doing a _google search_, not with it not working, not resolving, not connecting. Attention to detail is important, because I was looking for completely different reasons 'till you gave a full list of stuff I was _really_ sure would not cause google searches.
Comment 29 Gerald Butler 2009-11-10 17:12:17 UTC
(In reply to comment #28)
> (In reply to comment #27)
> > BTW, I also re-added the "localhost" to the Link Local IPv6 address in
> > /etc/hosts. Once I fixed /etc/gai.conf that was no longer required to be
> > removed. For anyone else interest, please review Bug 526321.
> 
> Great =). Just a comment, Xan and I asked the questions we have because we
> noticed you were not having the same problem as this bug report. Notice that
> this bug report deals with 'localhost:8000' doing a _google search_, not with
> it not working, not resolving, not connecting. Attention to detail is
> important, because I was looking for completely different reasons 'till you
> gave a full list of stuff I was _really_ sure would not cause google searches.

Yes, I realize that now. That is why I included the detailed list of what would and wouldn't work because I was starting to think we weren't talking about the same bug. Unfortunately, I had orginally submitted this other bug 597807 and it was marked as duplicate of this bug and I blindly followed that it was the same bug without examining it to carefully. My apologies.