I can curl with ipv6 succesfully but not with ipv4.
> curl -4 icanhazip.com
curl: (7) Failed to connect to icanhazip.com port 80: No route to host
But with ipv6 it's successful
> curl icanhazip.com
2601:681:5100:3e07::7bd4
I have raspap-webgui installed using a static IP on Raspian Stretch Lite on a Raspberry Pi Zero W.
ifconfig:
lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10<host>
loop txqueuelen 1000 (Local Loopback)
RX packets 400 bytes 32109 (31.3 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 400 bytes 32109 (31.3 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
usb0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 169.254.242.203 netmask 255.255.0.0 broadcast 169.254.255.255
inet6 fe80::afaa:427d:2758:6d5d prefixlen 64 scopeid 0x20<link>
ether fe:c5:01:98:ad:d0 txqueuelen 1000 (Ethernet)
RX packets 1103 bytes 138145 (134.9 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 638 bytes 97092 (94.8 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
wlan0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 10.3.141.1 netmask 255.255.255.0 broadcast 10.3.141.255
inet6 2601:681:5100:3e07::7bd4 prefixlen 128 scopeid 0x0<global>
inet6 fe80::4ffd:94d1:1cc0:5b60 prefixlen 64 scopeid 0x20<link>
inet6 2601:681:5100:3e07:556b:6800:413a:5ded prefixlen 64 scopeid 0x0<global>
ether b8:27:eb:a4:80:7e txqueuelen 1000 (Ethernet)
RX packets 529 bytes 74655 (72.9 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 226 bytes 27286 (26.6 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
Route Tables:
> route -A inet
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
default 10.3.141.1 0.0.0.0 UG 303 0 0 wlan0
10.3.141.0 0.0.0.0 255.255.255.0 U 303 0 0 wlan0
link-local 0.0.0.0 255.255.0.0 U 202 0 0 usb0
> route -A inet6
Kernel IPv6 routing table
Destination Next Hop Flag Met Ref Use If
2601:681:5100:3e07::/64 [::] U 303 1 0 wlan0
fe80::/64 [::] U 256 2 9 usb0
fe80::/64 [::] U 256 1 0 wlan0
[::]/0 fe80::250:f1ff:fe80:0 UG 303 2 76 wlan0
[::]/0 [::] !n -1 1 86 lo
localhost/128 [::] Un 0 3 3 lo
2601:681:5100:3e07::7bd4/128 [::] Un 0 3 43 wlan0
2601:681:5100:3e07:556b:6800:413a:5ded/128 [::] Un 0 2 0 wlan0
fe80::4ffd:94d1:1cc0:5b60/128 [::] Un 0 3 15 wlan0
fe80::afaa:427d:2758:6d5d/128 [::] Un 0 3 16 usb0
ff00::/8 [::] U 256 2 54 usb0
ff00::/8 [::] U 256 2 297 wlan0
[::]/0 [::] !n -1 1 89 lo
Edit:
> systemd-resolve --status
Global
DNS Servers: 1.1.1.1
DNSSEC NTA: 10.in-addr.arpa
16.172.in-addr.arpa
168.192.in-addr.arpa
17.172.in-addr.arpa
18.172.in-addr.arpa
19.172.in-addr.arpa
20.172.in-addr.arpa
21.172.in-addr.arpa
22.172.in-addr.arpa
23.172.in-addr.arpa
24.172.in-addr.arpa
25.172.in-addr.arpa
26.172.in-addr.arpa
27.172.in-addr.arpa
28.172.in-addr.arpa
29.172.in-addr.arpa
30.172.in-addr.arpa
31.172.in-addr.arpa
corp
d.f.ip6.arpa
home
internal
intranet
lan
local
private
test
Link 3 (wlan0)
Current Scopes: LLMNR/IPv4 LLMNR/IPv6
LLMNR setting: yes
MulticastDNS setting: no
DNSSEC setting: no
DNSSEC supported: no
Link 2 (usb0)
Current Scopes: none
LLMNR setting: yes
MulticastDNS setting: no
DNSSEC setting: no
DNSSEC supported: no
dig
> dig -t A icanhazip.com
; <<>> DiG 9.10.3-P4-Raspbian <<>> -t A icanhazip.com
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 10101
;; flags: qr rd ra; QUERY: 1, ANSWER: 3, AUTHORITY: 0, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 512
;; QUESTION SECTION:
;icanhazip.com. IN A
;; ANSWER SECTION:
icanhazip.com. 300 IN A 147.75.89.25
icanhazip.com. 300 IN A 147.75.96.57
icanhazip.com. 300 IN A 147.75.92.157
;; Query time: 23 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Thu Mar 21 22:38:40 GMT 2019
;; MSG SIZE rcvd: 90