RFR: JDK-8184770: JDWP support for IPv6

Alex Menkov alexey.menkov at oracle.com
Mon Apr 1 21:13:39 UTC 2019


Hi Daniel,

As far as I see you are right.
Attach to address with empty hostname will try to connect to "external" 
address instead of loopback.

--alex

On 04/01/2019 02:51, Daniel Fuchs wrote:
> Hi Arthur,
> 
> Not directly related to Alex's original question but...
> 
> On 30/03/2019 00:03, Arthur Eubanks wrote:
>> We have some ipv6 patches as well in this area as well (as well as 
>> other patches to support ipv6 only environments) that we're trying to 
>> upstream. I don't understand the code myself, but it might be useful 
>> to take a look:
>> http://cr.openjdk.java.net/~aeubanks/jdwpipv6/webrev.00/index.html
> 
> SocketTransportService.java:
> 
> On my machine at least, InetAddress.getByName("localhost") and
> InetAddress.getLocalHost() are quite different:
> 
> 
> InetAddress.getByName("localhost") will return the loopback (127.0.0.1)
> InetAddress.getLocalHost() returns the local hostname (dhcp-XXX-XXX...)
> 
> If I'm not mistaken your changes in HostPort would transform something
> that previously returned the loopback (no host specified) with something
> that returns the local host name ("*" specified).
> 
> 
> So I'm not sure these changes are quite right.
> Maybe Alex will be able to confirm.
> 
> best regards,
> 
> -- daniel


More information about the serviceability-dev mailing list