2

I have busybox 1.9.1 runing in huawei router. There is few commands, one of them wget and I want to use it, but there is some strange syntax.

When I type wget www.google.com like I do normaly on my debian/mint etc, i get help message in this form:

Usage: wget [OPTION]... HOST

wget download and upload a file via HTTP

Options:
        -g    Download
        -s    Upload
        -v    Verbose
        -u    Username to be used
        -p    Password to be used
        -l    Local file path
        -r    Remote file path
        -P    Port to be used, optional
        -B    Bind local ip, optional
        -A    Remote resolved ip, optional
        -b    Transfer start position
        -e    Transfer length
        -m    Max transfer size
        -c    Compress downloaded file

I tried to use anything, like wget -g url or wget -g -r url, but nothing works, i always get only this help message again. Can someone help me?

busybox
  • 21
  • 1
  • 1
  • 2
  • Does it work if you specify the protocol? eg http:// ? And does it work if you try an IP-based url (eg wget http://127.0.0.1/). And have you tried running su -before attempting the wget? – Adam Thompson Aug 23 '13 at 11:06
  • Hello, i tried both http:// and ip-based url, nothing worked. su is not working on this busybox ( not found ) – busybox Aug 23 '13 at 11:18
  • Just thinking - the output of wget you've posted doesn't look like what BusyBox shows in their documentation - http://www.busybox.net/downloads/BusyBox.html#wget. Is this another version of wget, or the one that comes with BusyBox? – Adam Thompson Aug 23 '13 at 11:32
  • Well, I get into this busybox throught huawei console via telneting my router and then using command "shell" in their console, so the busybox was probably specially crafted by huawei – busybox Aug 23 '13 at 11:38

2 Answers2

2

I'm not sure why the other user was voted down. The correct syntax for my Huawei HG610 router is exactly as he says.

For example:

wget -g -v -l /tmp/test.html -r / 192.168.0.11

The above will retrieve the page at http://192.168.0.11/ and save it to /tmp/test.html

0

Hey I had the same problem and finally got the correct syntax:

wget -g -v -l "path to save the file" -r "path to remote file" host (without http://)

hope it helps