Assuming you have a curl compiled with IPv6, if you wanted to hit a page using its IPv6 address rather than its hostname, you have to do it as follows:
curl "http://\[2600:xxx:yyy::zzz\]/page.html"
The square brackets are required to tell curl that it's an IPv6 address and not a host:port pair.
The quotes are required to stop the shell from treating the square brackets as a glob.
The backslash is required to stop curl from treating the square brackets as a range specification.
The
http://
is optional, but good form.
This isn't required if you use a hostname or an IPv4 address.
0 comments :
Post a Comment