Disclaimer: networking is not my strong suit. This may be a very basic question.
Why, when I bind a socket to 0.0.0.0
, does Java also bind to the equivalent of ::
(IP6)? I thought that 0.0.0.0
, being in dotted quad notation, represents "any IP4 address", not "any IP address, 4 and/or 6".
I'm aware of the -Djava.net.preferIPv4Stack=true
system property setting, but I'm not asking about that. I'm asking specifically why Java interprets 0.0.0.0
as "any address at all, IP4 or IP6".