[LEDE-DEV] Busybox weirdness

tv.debian at googlemail.com tv.debian at googlemail.com
Thu Nov 2 00:45:39 PDT 2017


On 02/11/2017 09:42, Philip Prindeville wrote:
> 
>> On Nov 1, 2017, at 8:36 PM, Philip Prindeville <philipp_subx at redfish-solutions.com> wrote:
>>
>> Can someone else please try to reproduce this?
>>
>> I’m using busybox’s wget on x86_64 hardware, and when I do a “wget” of 2 http: URI’s, it mangles the second URI’s derived filename:
>>
>>
>> root at lede:/tmp/x# c
>> Downloading 'http://geolite.maxmind.com/download/geoip/database/GeoIPv6.csv.gz'
>> Connecting to 104.16.37.47:80
>> Writing to 'GeoIPv6.csv.gz'
>> GeoIPv6.csv.gz       100% |*******************************|  1496k  0:00:00 ETA
>> Download completed (1532219 bytes)
>> Connecting to 104.16.37.47:80
>> Writing to ' z;'
>> z;               100% |*******************************|  2338k  0:00:00 ETA
>> Download completed (2394696 bytes)
>> root at lede:/tmp/x# ls
>> z;??          GeoIPv6.csv.gz
>> root at lede:/tmp/x#
>>
>>
>> What the heck?
>>
>> -Philip
> 
> 
> Well, I was selecting busybox’s wget, but it was silently being overwritten by something else:
> 
> root at lede:/tmp/x# ls -l /bin/wget
> lrwxrwxrwx    1 root     root            13 Nov  1 19:17 /bin/wget -> uclient-fetch
> root at lede:/tmp/x#
> 
> so that’s the real culprit.
> 
> 
> _______________________________________________
> Lede-dev mailing list
> Lede-dev at lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/lede-dev
> 

I can reproduce partially (17.01.4), here I get garbled filename that 
seems due to charset mismatch:

wget http://geolite.maxmind.com/download/geoip/database/GeoIPv6.csv.gz 
http://geolite.maxmind.com/download/geoip/da
tabase/GeoIPCountryCSV.zip
Downloading 
'http://geolite.maxmind.com/download/geoip/database/GeoIPv6.csv.gz'
Connecting to 2400:cb00:2048:1::6810:262f:80
Writing to 'GeoIPv6.csv.gz'
GeoIPv6.csv.gz       100% |*******************************|  1496k 
0:00:00 ETA
Download completed (1532219 bytes)
Connecting to 2400:cb00:2048:1::6810:252f:80
Writing to '������csv.gz'
������csv.gz       100% |*******************************|  2338k 
0:00:00 ETA
Download completed (2394696 bytes)

It also misbehaves if the download is somehow redirected over https, for 
example while downloading wrtbwmon i get:

wget 
https://github.com/Kiougar/luci-wrtbwmon/releases/download/v0.6.0/luci-wrtbwmon_0.6.0_all.ipk
Downloading 
'https://github.com/Kiougar/luci-wrtbwmon/releases/download/v0.6.0/luci-wrtbwmon_0.6.0_all.ipk'
Connecting to 192.30.253.112:443
Redirected to 
/77686685/247a31e2-494d-11e7-818a-29601f00a0dc?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20171102%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20171102T073145Z&X-Amz-Expires=300&X-Amz-Signature=fc898a693aeb4664ba1bc51de9ae2d2f791707e50829d7fb9b4ceaae4d99bd53&X-Amz-SignedHeaders=host&actor_id=0&response-content-disposition=attachment%3B%20filename%3Dluci-wrtbwmon_0.6.0_all.ipk&response-content-type=application%2Foctet-stream 
on github-production-release-asset-2e65be.s3.amazonaws.com
Writing to 
'247a31e2-494d-11e7-818a-29601f00a0dc?X-Amz-Algorithm=AWS4-HMAC-SHA256'
247a31e2-494d-11e7-8 100% |*******************************|  5245 
0:00:00 ETA
Download completed (5245 bytes)

None of this happens with plain wget (and ca-certificates) installed.



More information about the Lede-dev mailing list