Bug 105931 - DNS: CNAME does not work correctly
Summary: DNS: CNAME does not work correctly
Status: RESOLVED INTENTIONAL
Alias: None
Product: konqueror
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: Unassigned bugs mailing-list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-05-19 08:34 UTC by Mario Weilguni
Modified: 2011-05-25 20:36 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mario Weilguni 2005-05-19 08:34:57 UTC
Version:            (using KDE KDE 3.4.0)
Installed from:    Compiled From Sources

Suppose my domain is test.at. I have an internal webserver that responds to "foo.test.at" and "foo" alone as well.

Now, foo is defined as CNAME in my DNS, pointing to "webserver.test.at"
When I now open "foo" with konqueror, the browser jumps to "webserver.test.at", and that fails (because the HTTP hostname is wrong). It should use the adress "webserver.test.at" and still use "foo" as hostname.

If someone could point me where to best look for this problem I might fix it myself and prepare a patch.
Comment 1 Thiago Macieira 2005-05-20 14:05:09 UTC
I see the problem, but I can't reproduce it.

It may be a problem in kio_http, but I think it is in the short URI filter.
Comment 2 Mario Weilguni 2005-05-21 09:29:24 UTC
I noticed another strange problem. This fails only the first time when I try "foo" in konqueror, subsequents requests for "foo" work as expected. There has to be some problem in the DNS logic here.
Comment 3 Thiago Macieira 2005-05-21 15:55:08 UTC
There were problems a while ago that we have fixed. Make sure you're running the latest in branch.
Comment 4 Thiago Macieira 2005-08-15 04:54:46 UTC
Any developments?
Comment 5 Kolbjørn Barmen 2005-11-10 16:17:26 UTC
Same problem here, with 3.4.2, 3.4.3 and 3.5.0_beta2.

"foo CNAME bar" in mydomain.com
I type "foo" in location and get sent to "http://bar.mydomain.com"
I type "http://foo" in location and get sent to "http://foo.mydomain.com"

It seems that if protocol is not given, it will look up "foo" in DNS first (and follow CNAME), and then add default protool (http:) afterwards.
Comment 6 Thiago Macieira 2005-11-10 20:25:29 UTC
I've reproduced this now (r477777), but it must be in the kshorturifilter (which is something I proposed to improve since KDE 3.3, but never got around to).
Comment 7 Dawit Alemayehu 2010-05-04 18:21:14 UTC
This is neither a kio_http bug nor an issue in kshorturifilter. Actually it is kshorturifilter that saves you when you type "http://foo" because it thinks that is a valid url which prevents any further processing by the other uri filter plugins. 

What causes your problem is localdomainurifilter which can be found at kdebase/runtime/kurifilter-plugins/localdomain. Unfortunately it is written to do exactly what you do not want. For now the only way to fix this issue is to remove the offending uri filter plugin library, localdomainurifilter.so, from your KDE installation.

The proper fix would be a configuration option that prevents the use of this or any urifilter plugin at the application level. Specifically Konqueror or any other browser can provide such configuration options.
Comment 8 Dawit Alemayehu 2011-05-25 20:36:56 UTC
See my first comment in bug 207550 on how to disable the localdomainurifilter. That should resolve this problem.