Closed
Description
I did this (host/ip are intentionally obfuscated)
curl -v --resolve 'myhost.domain.com:443:[dead:beef:1234:5678:8765:4321:feed:daed]' https://myhost.domain.com
I expected the following
For myhost.domain.com
to resolve to [dead:beef:1234:5678:8765:4321:feed:daed]
, but what I got was:
curl -v --resolve 'myhost.domain.com:443:dead:beef:1234:5678:8765:4321:feeb:daed' https://myhost.domain.com
* Address in 'myhost.domain.com:443:[dead:beef:1234:5678:8765:4321:feed:daed]' found illegal!
If I specify the IPv6 address incorrectly, that is without the brackets, then it works as expected:
curl -v --resolve 'myhost.domain.com:443:dead:beef:1234:5678:8765:4321:feeb:daed' https://myhost.domain.com
* Added myhost.domain.com:443:dead:beef:1234:5678:8765:4321:feeb:daed to DNS cache
* Rebuilt URL to: https://myhost.domain.com/
* Hostname myhost.domain.com was found in DNS cache
* Trying dead:beef:1234:5678:8765:4321:feeb:daed...
curl/libcurl version
curl 7.55.1 (x86_64-pc-linux-gnu) libcurl/7.55.1 OpenSSL/1.0.2g zlib/1.2.11 libidn2/2.0.2 libpsl/0.18.0 (+libidn2/2.0.2) librtmp/2.3
Release-Date: 2017-08-14
Protocols: dict file ftp ftps gopher http https imap imaps ldap ldaps pop3 pop3s rtmp rtsp smb smbs smtp smtps telnet tftp
Features: AsynchDNS IDN IPv6 Largefile GSS-API Kerberos SPNEGO NTLM NTLM_WB SSL libz TLS-SRP UnixSockets HTTPS-proxy PSL
operating system
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 17.10
Release: 17.10
Codename: artful
Metadata
Metadata
Assignees
Labels
No labels