curl/trurl

-s host=[::1] fails

bagder opened this issue · 1 comments

... because trurl always URL encodes the given string (unless := is used), and when setting an IPv6 address it gets URL encoded into "rubbish".

Maybe we should consider special-casing a leading bracket ([) when setting a host name and disable URL encoding then?

Maybe we should just accept that it works like this and maybe highlight it a little better in the docs?

piru commented

There are arguments both ways:

  • "host=[::1]" failing (at least when documentation doesn't highlight the need of :=) can be confusing.
  • Exceptions to encoding rules are probably not great either