Version: (using KDE KDE 3.1.4) Installed from: Debian testing/unstable Packages OS: Linux RFC 2782 defines a DNS RR to specify where services are located, server address and port. It gave ability to host different services at different machines without being forced to name them according to their purpose (even with aliases), and also to use fine load-balancing and failover. Konqueror should resolve an HTTP URI with SRV RR. (maybe KDE should provide globally a way to do it...)
It's been in my TO-DO list for a couple of years. I hope to get it working for KDE 3.3. I am lacking, though, a working implementation to base on or use.
You could dig in these projects: http://libsrv.sourceforge.net/ http://www.nongnu.org/ruli/
Thank you, I will take a look.
*** Bug 93904 has been marked as a duplicate of this bug. ***
DNS SRV support should be provided throughout, not just kio_http but kio_ftp, webdav, fish, etc.
I am working on this: http://websvn.kde.org/branches/work/srv-resolution/
I forgot to CC this bug. SVN commit 443592 by thiago: Merging branch in branches/work/kdecorenetwork-srv-resolution back to the main line: implements SRV-based DNS lookups according to RFC 2782. The code is in working condition and should compile for everyone. Bug me if it doesn't. Missing feature: sort the per-priority entries according to weight. This is a "SHOULD" feature according to the RFC. I'll implement it somewhen. Foward-port to KDE4 will not happen now because there's no QDns replacement outside the Qt3Support library. M +3 -1 Makefile.am M +4 -2 kresolver.h M +10 -1 kresolvermanager.cpp A ksrvresolverworker.cpp branches/work/kdecorenetwork-srv-resolution/ksrvresolverworker.cpp#443589 A ksrvresolverworker_p.h branches/work/kdecorenetwork-srv-resolution/ksrvresolverworker_p.h#443589 --- branches/KDE/3.5/kdelibs/kdecore/network/Makefile.am #443591:443592 @@ -26,7 +26,8 @@ khttpproxysocketdevice.cpp \ ksockssocketdevice.cpp \ kbufferedsocket.cpp \ - ksocketbuffer.cpp + ksocketbuffer.cpp \ + ksrvresolverworker.cpp include_HEADERS = kresolver.h \ kreverseresolver.h \ @@ -48,6 +49,7 @@ kresolverworkerbase.h \ kresolverstandardworkers_p.h \ ksocketbuffer_p.h \ + ksrvresolverworker_p.h \ syssocket.h configdir = $(kde_confdir) --- branches/KDE/3.5/kdelibs/kdecore/network/kresolver.h #443591:443592 @@ -341,7 +341,8 @@ * be found and recorded * @li NoResolve: request that no external resolution be performed. The given * nodename and servicename will be resolved locally only. - * @li NoSrv: don't try to use SRV-based name-resolution. + * @li NoSrv: don't try to use SRV-based name-resolution. (deprecated) + * @li UseSrv: use SRV-based name resolution. * @li Multiport: the port/service argument is a list of port numbers and * ranges. (future extension) * @@ -353,7 +354,8 @@ CanonName = 0x02, NoResolve = 0x04, NoSrv = 0x08, - Multiport = 0x10 + Multiport = 0x10, + UseSrv = 0x20 }; /** --- branches/KDE/3.5/kdelibs/kdecore/network/kresolvermanager.cpp #443591:443592 @@ -53,8 +53,16 @@ #include "kresolver.h" #include "kresolver_p.h" #include "kresolverworkerbase.h" -#include "kresolverstandardworkers_p.h" +namespace KNetwork +{ + namespace Internal + { + void initSrvWorker(); + void initStandardWorkers(); + } +} + using namespace KNetwork; using namespace KNetwork::Internal; @@ -325,6 +333,7 @@ globalManager = this; workers.setAutoDelete(true); currentRequests.setAutoDelete(true); + initSrvWorker(); initStandardWorkers(); pid = getpid();
If a SHOULD feature doesn't work, shouldn't this bug remain open?
SRV resolution works. Bug closed. The weighing per priority is subject of a new bug (wish) report.