We have a couple of web servers which default to requiring a username and no password (or a blank password). As long as I specify an --http-user & --http-passwd then wget works, but if I only specify a username and no password then wget simply ignores the username. I believe this is a bug. I believe the correct behaviour would be for the --http-passwd option to default to blank if it is not specified but --http-username is specificed. See the two examples below:
Here wget works if username is specified together with a blank password: [root@vectra wget-1.8.2]# wget -S -v --http-user=admin --http-passwd= http://server/ --16:57:55-- http://server/ => `index.html' Connecting to server:80... connected. HTTP request sent, awaiting response... 1 HTTP/1.0 200 Document follows 2 Server: 3Com/v1.0 3 Expires: Mon, 1 Jan 2001 12:00:00 GMT 4 Pragma: no-cache 5 Cache-control: no-cache [ <=> 80 78.12K/s 16:57:55 (78.12 KB/s) - `index.html' saved [80] Here it fails if I specifiy a username and no password because wget doesn't try to authenticate at all: [root@vectra wget-1.8.2]# wget -S -v --http-user=admin http://server/ --16:58:10-- http://server/ => `index.html.1' Connecting to server:80... connected. HTTP request sent, awaiting response... 1 HTTP/1.0 401 Unauthorized 2 Server: 3Com/v1.0 3 Content-length: 89 4 WWW-Authenticate:Basic realm="device" 5 Content-type: text/html Authorization failed. Please copy me on any replies since I am not subscribed to the list. Thanks, Jon