Package: apt-proxy
Version: 1.9.32
Severity: normal

somewhere along the line apt-proxy stopped handling ftp
username/password correctly and was leaving the '@' symbol on the start
of the host name.


Below is a copy of the error from the logs and two patches.

There are two patches as I'm not really a python programmer and not really sure 
which way is best.
I like the first one my self since it uses one less function call.

--- apt_proxy.py.orig   2005-08-20 03:15:20.000000000 +1000
+++ apt_proxy.py        2006-01-20 19:52:58.000000000 +1100
@@ -1305,8 +1305,7 @@
                      query, fragment = urlparse.urlparse(uri)
 
         if '@' in netloc:
-            auth = netloc[:netloc.rindex('@')]
-            netloc = netloc[netloc.rindex('@'):]
+            auth, netloc = netloc.split('@')
             self.username, self.password = auth.split(':')
         else:
             self.username = None




--- apt_proxy.py.orig   2005-08-20 03:15:20.000000000 +1000
+++ apt_proxy.py        2006-01-20 19:52:02.000000000 +1100
@@ -1306,7 +1306,7 @@
 
         if '@' in netloc:
             auth = netloc[:netloc.rindex('@')]
-            netloc = netloc[netloc.rindex('@'):]
+            netloc = netloc[netloc.rindex('@') + 1:]
             self.username, self.password = auth.split(':')
         else:
             self.username = None



006/01/20 19:33 EST [Channel,22,127.0.0.1] [Fetcher.activate] (debian) 
servers:1/debian/dists/sid/contrib/source/Sources.gz
2006/01/20 19:33 EST [Channel,22,127.0.0.1] Starting factory 
<twisted.internet.protocol._InstanceFactory instance at 0xb6c45fcc
>
2006/01/20 19:33 EST [-] Stopping factory 
<twisted.internet.protocol._InstanceFactory instance at 0xb6c45fcc>
2006/01/20 19:33 EST [-] [Fetcher] Connection Failed: [Failure instance: 
Traceback (failure with no frames): twisted.internet.e
rror.DNSLookupError: DNS lookup failed: address '@premium.planetmirror.com' not 
found: (-2, 'Name or service not known').
        ]
2006/01/20 19:33 EST [-] "[error] [debian] Connection Failed: 
/pub/debian/dists/sid/contrib/source/Sources.gz (DNS lookup faile
d: address '@premium.planetmirror.com' not found: (-2, 'Name or service not 
known').)"
2006/01/20 19:33 EST [-] [fetcher] no more Backends
2006/01/20 19:33 EST [-] [Fetcher] Finished receiving data, status:503 
saveData:0
2006/01/20 19:33 EST [-] [Fetcher] Last request removed
2006/01/20 19:33 EST [Channel,22,127.0.0.1] [debug] Client connection closed
2006/01/20 19:33 EST [Channel,22,127.0.0.1] Top 10:
2006/01/20 19:33 EST [Channel,22,127.0.0.1]        274 WeakKeyDictionary
2006/01/20 19:33 EST [Channel,22,127.0.0.1]        153 SelectReactor
2006/01/20 19:33 EST [Channel,22,127.0.0.1]         90 Exception
2006/01/20 19:33 EST [Channel,22,127.0.0.1]         76 DelayedCall
2006/01/20 19:33 EST [Channel,22,127.0.0.1]         28 DBError
2006/01/20 19:33 EST [Channel,22,127.0.0.1]         27 Deferred
2006/01/20 19:33 EST [Channel,22,127.0.0.1]         26 Protocol
2006/01/20 19:33 EST [Channel,22,127.0.0.1]         24 StandardError
2006/01/20 19:33 EST [Channel,22,127.0.0.1]         24 ProtocolToConsumerAdapter
2006/01/20 19:33 EST [Channel,22,127.0.0.1]         17 Warning
2006/01/20 19:34 EST [-] [recycle] Pruning empty directory: 
/var/cache/apt-proxy/debian/dists/sid


-- System Information:
Debian Release: testing/unstable
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: i386 (i686)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.15-1-686
Locale: LANG=en_AU, LC_CTYPE=en_AU (charmap=ISO-8859-1)


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to