Hurricane Electric's IPv6 Tunnel Broker Forums

Advanced search  

News:

Welcome to Hurricane Electric's Tunnelbroker.net forums!

Author Topic: badauth on IP udpate  (Read 2316 times)

risa2000

  • Newbie
  • *
  • Posts: 1
badauth on IP udpate
« on: April 12, 2015, 12:05:46 PM »

I have configured a tunnel, which works fine, except I cannot get the IP address update working. I am using the following HTTP request:
Code: [Select]
http://ipv4.tunnelbroker.net/nic/update?username=<myname>&password=<myupdatekey>&hostname=<mytunnel>If I put it into Chrome (Windows 7 64 bit), it returns OK, but it seems that:
a) Chrome is somehow authenticated to "tunnelbroker.net" realm already
b) Chrome defaults to HTTPS even if I put the HTTP into the request

However if I try the same HTTPS in Internet Explorer (same OS) I got a dialog prompt for authentication credentials for "tunnelbroker.net" realm. Is it supposed to work this way? I would expect that password in the URL is already authenticating the access.

Entering my username and my update key as the password in IE authentication dialog works.

Then I tried to run it on gentoo using curl and as long as I do not specify .netrc with my username and my update key as the password for ipv4.tunnelbroker.net I cannot get it running:
Code: [Select]
risa@gentoo-vb ~ $ curl -v "http://ipv4.tunnelbroker.net/nic/update?username=<myname>&password=<myupdatekey>&hostname=<mytunnel>"
* Hostname was NOT found in DNS cache
*   Trying 64.62.200.2...
* Connected to ipv4.tunnelbroker.net (64.62.200.2) port 80 (#0)
> GET /nic/update?username=<myname>&password=<myupdatekey>&hostname=<mytunnel> HTTP/1.1
> User-Agent: curl/7.39.0
> Host: ipv4.tunnelbroker.net
> Accept: */*
>
* HTTP 1.0, assume close after body
< HTTP/1.0 401 NI
< Date: Sun, 12 Apr 2015 18:26:16 GMT
< Server: Apache/2.2.22 (Ubuntu) DAV/2 SVN/1.6.17 PHP/5.3.10-1ubuntu3.15 with Suhosin-Patch mod_ssl/2.2.22 OpenSSL/1.0.1 mod_perl/2.0.5 Perl/v5.14.2
< X-Powered-By: PHP/5.3.10-1ubuntu3.15
< Set-Cookie: referer=Direct+Access
< Strict-Transport-Security: max-age=15768000
< WWW-Authenticate: Basic realm="tunnelbroker.net"
< Content-Length: 8
< Connection: close
< Content-Type: text/html; charset=utf-8
<
badauth
* Closing connection 0

As soon as I use .netrc it runs fine (and I can remove password and username from the URL):
Code: [Select]
risa@gentoo-vb ~ $ curl -kv --netrc "http://ipv4.tunnelbroker.net/nic/update?hostname=<mytunnel>"
* Hostname was NOT found in DNS cache
*   Trying 64.62.200.2...
* Connected to ipv4.tunnelbroker.net (64.62.200.2) port 80 (#0)
* Server auth using Basic with user '<myname>'
> GET /nic/update?hostname=<mytunnel> HTTP/1.1
> Authorization: Basic cmlzYTIwMDA6OTY5OTk0NTNNQmF5RG0rWg==
> User-Agent: curl/7.39.0
> Host: ipv4.tunnelbroker.net
> Accept: */*
>
* HTTP 1.0, assume close after body
< HTTP/1.0 200 ok
< Date: Sun, 12 Apr 2015 18:53:48 GMT
< Server: Apache/2.2.22 (Ubuntu) DAV/2 SVN/1.6.17 PHP/5.3.10-1ubuntu3.15 with Suhosin-Patch mod_ssl/2.2.22 OpenSSL/1.0.1 mod_perl/2.0.5 Perl/v5.14.2
< X-Powered-By: PHP/5.3.10-1ubuntu3.15
< Set-Cookie: referer=Direct+Access
< Strict-Transport-Security: max-age=15768000
< Content-Length: 19
< Connection: close
< Content-Type: text/html; charset=utf-8
<
nochg <myIP>
* Closing connection 0

Is this an intended behavior?
Logged