[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openjdk-serviceability-dev
Subject:    Re: RFR: JDK-8184770: JDWP support for IPv6
From:       Arthur Eubanks <aeubanks () google ! com>
Date:       2019-03-30 0:06:43
Message-ID: CAPW48sqbpVy9V_2krrgt12cdO2f-O-xxC3jXHhpe+9c-xZLs+w () mail ! gmail ! com
[Download RAW message or body]

(one more time now that I'm subscribed to serviceability-dev)

On Fri, Mar 29, 2019 at 5:03 PM Arthur Eubanks <aeubanks@google.com> 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
>
> On Fri, Mar 29, 2019 at 3:09 PM Alex Menkov <alexey.menkov@oracle.com>
> wrote:
>
>> (added net-dev as suggested by Alan)
>>
>> Net gurus, please assist in reviewing socket-related code.
>>
>> New webrev:
>> http://cr.openjdk.java.net/~amenkov/IPv6/webrev.01/
>>
>>
>> On 03/28/2019 07:44, Gary Adams wrote:
>> > Is there any documentation that needs to be updated along with the impl
>> > changes?
>>
>> created an issue for this:
>> https://bugs.openjdk.java.net/browse/JDK-8221707
>>
>> >
>> > Would it make sense to support the preference properties?
>> >    java.net.preferIPv4Stack
>> >    java.net.preferIPv6Addresses
>>
>> Done (with new test for the functionality)
>>
>> >
>> > Will the previous jdwp tests run with IPv6 or just the new additions?
>>
>> many tests use "localhost" (or empty string which has the same meaning)
>> address. localhost can be resolved to IPv4 or IPv6 address, but by
>> default IPv4 is used.
>> So IPv6 will be used only on IPv6-only systems.
>>
>> >
>> > Should probably have reviewers with networking expertise. core-libs(?)
>> >
>> > Do we know if IPv6 is enabled in our test infrastructure?
>>
>> Accordingly the logs IPv6 stack is enabled, but no external IPv6 address
>> is assigned (i.e. the only IPv6 address is loopback - ::1). This is
>> enough for testing.
>>
>> >
>> > A stray "printf" statement in the initial webrev. socketTransport.c
>>
>> fixed.
>>
>> --alex
>>
>> >
>> > On 3/27/19, 7:04 PM, Alex Menkov wrote:
>> >> Hi all,
>> >>
>> >> Please review the fix for
>> >> https://bugs.openjdk.java.net/browse/JDK-8184770
>> >> webrev:
>> >> http://cr.openjdk.java.net/~amenkov/IPv6/webrev.00/
>> >>
>> >> Main changes are in socketTransport.c - the code is updated to support
>> >> both IPv4 and IPv6.
>> >> Some details to simplify reviewing:
>> >> - listening:
>> >>   - if IP address is specified (like 127.0.0.1 or ::1), connector
>> >> listens only on this address;
>> >>   - for backward compatibility if no address (or "localhost") is
>> >> specified, IPv4 is used (if supported by the host);
>> >>   - if "*" is specified (means "listen on all local interfaces"), dual
>> >> mode socket is used to listen on both IPv6 and IPv4 addresses;
>> >>   - AllowedPeerInfo structure (for "allow" option) is updated to use
>> >> IPv6 address/mask, support for IPv4 is implemented by using "mapped"
>> >> IPv4 addresses;
>> >> - attaching: agent resolves and tries to connect to all (IPv4 and
>> >> IPv6) addresses, IPv4 are tried first;
>> >>
>> >> SocketListeningConnector.java/SocketTransportService.java are updated
>> >> to support IPv6 addresses (the addresses may contain colons);
>> >>
>> >> new JdwpAttachTest.java/JdwpListenTest.java test that listening and
>> >> attaching works for all available addresses (Ipv4 and IPv6)
>> >>
>> >> BasicJDWPConnectionTest.java was renamed to JdwpAllowTest.java (as it
>> >> tests "allow" functionality), tests for mask (prefix length)
>> >> functionality are added (for both IPv4 and IPv6);
>> >>
>> >> --alex
>> >
>>
>

[Attachment #3 (text/html)]

<div dir="ltr">(one more time now that I&#39;m subscribed to \
serviceability-dev)</div><br><div class="gmail_quote"><div dir="ltr" \
class="gmail_attr">On Fri, Mar 29, 2019 at 5:03 PM Arthur Eubanks &lt;<a \
href="mailto:aeubanks@google.com">aeubanks@google.com</a>&gt; \
wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px \
0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">We have \
some ipv6 patches as well in this area as well (as well as other patches to support \
ipv6 only environments) that we&#39;re trying to upstream. I don&#39;t understand the \
code myself, but it might be useful to take a look:<div><a \
href="http://cr.openjdk.java.net/~aeubanks/jdwpipv6/webrev.00/index.html" \
target="_blank">http://cr.openjdk.java.net/~aeubanks/jdwpipv6/webrev.00/index.html</a><br></div></div><br><div \
class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Mar 29, 2019 at 3:09 PM \
Alex Menkov &lt;<a href="mailto:alexey.menkov@oracle.com" \
target="_blank">alexey.menkov@oracle.com</a>&gt; wrote:<br></div><blockquote \
class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid \
rgb(204,204,204);padding-left:1ex">(added net-dev as suggested by Alan)<br> <br>
Net gurus, please assist in reviewing socket-related code.<br>
<br>
New webrev:<br>
<a href="http://cr.openjdk.java.net/~amenkov/IPv6/webrev.01/" rel="noreferrer" \
target="_blank">http://cr.openjdk.java.net/~amenkov/IPv6/webrev.01/</a><br> <br>
<br>
On 03/28/2019 07:44, Gary Adams wrote:<br>
&gt; Is there any documentation that needs to be updated along with the impl <br>
&gt; changes?<br>
<br>
created an issue for this:<br>
<a href="https://bugs.openjdk.java.net/browse/JDK-8221707" rel="noreferrer" \
target="_blank">https://bugs.openjdk.java.net/browse/JDK-8221707</a><br> <br>
&gt; <br>
&gt; Would it make sense to support the preference properties?<br>
&gt;      java.net.preferIPv4Stack<br>
&gt;      java.net.preferIPv6Addresses<br>
<br>
Done (with new test for the functionality)<br>
<br>
&gt; <br>
&gt; Will the previous jdwp tests run with IPv6 or just the new additions?<br>
<br>
many tests use &quot;localhost&quot; (or empty string which has the same meaning) \
<br> address. localhost can be resolved to IPv4 or IPv6 address, but by <br>
default IPv4 is used.<br>
So IPv6 will be used only on IPv6-only systems.<br>
<br>
&gt; <br>
&gt; Should probably have reviewers with networking expertise. core-libs(?)<br>
&gt; <br>
&gt; Do we know if IPv6 is enabled in our test infrastructure?<br>
<br>
Accordingly the logs IPv6 stack is enabled, but no external IPv6 address <br>
is assigned (i.e. the only IPv6 address is loopback - ::1). This is <br>
enough for testing.<br>
<br>
&gt; <br>
&gt; A stray &quot;printf&quot; statement in the initial webrev. \
socketTransport.c<br> <br>
fixed.<br>
<br>
--alex<br>
<br>
&gt; <br>
&gt; On 3/27/19, 7:04 PM, Alex Menkov wrote:<br>
&gt;&gt; Hi all,<br>
&gt;&gt;<br>
&gt;&gt; Please review the fix for<br>
&gt;&gt; <a href="https://bugs.openjdk.java.net/browse/JDK-8184770" rel="noreferrer" \
target="_blank">https://bugs.openjdk.java.net/browse/JDK-8184770</a><br> &gt;&gt; \
webrev:<br> &gt;&gt; <a href="http://cr.openjdk.java.net/~amenkov/IPv6/webrev.00/" \
rel="noreferrer" target="_blank">http://cr.openjdk.java.net/~amenkov/IPv6/webrev.00/</a><br>
 &gt;&gt;<br>
&gt;&gt; Main changes are in socketTransport.c - the code is updated to support <br>
&gt;&gt; both IPv4 and IPv6.<br>
&gt;&gt; Some details to simplify reviewing:<br>
&gt;&gt; - listening:<br>
&gt;&gt;    - if IP address is specified (like 127.0.0.1 or ::1), connector <br>
&gt;&gt; listens only on this address;<br>
&gt;&gt;    - for backward compatibility if no address (or &quot;localhost&quot;) is \
<br> &gt;&gt; specified, IPv4 is used (if supported by the host);<br>
&gt;&gt;    - if &quot;*&quot; is specified (means &quot;listen on all local \
interfaces&quot;), dual <br> &gt;&gt; mode socket is used to listen on both IPv6 and \
IPv4 addresses;<br> &gt;&gt;    - AllowedPeerInfo structure (for &quot;allow&quot; \
option) is updated to use <br> &gt;&gt; IPv6 address/mask, support for IPv4 is \
implemented by using &quot;mapped&quot; <br> &gt;&gt; IPv4 addresses;<br>
&gt;&gt; - attaching: agent resolves and tries to connect to all (IPv4 and <br>
&gt;&gt; IPv6) addresses, IPv4 are tried first;<br>
&gt;&gt;<br>
&gt;&gt; SocketListeningConnector.java/SocketTransportService.java are updated <br>
&gt;&gt; to support IPv6 addresses (the addresses may contain colons);<br>
&gt;&gt;<br>
&gt;&gt; new JdwpAttachTest.java/JdwpListenTest.java test that listening and <br>
&gt;&gt; attaching works for all available addresses (Ipv4 and IPv6)<br>
&gt;&gt;<br>
&gt;&gt; BasicJDWPConnectionTest.java was renamed to JdwpAllowTest.java (as it <br>
&gt;&gt; tests &quot;allow&quot; functionality), tests for mask (prefix length) <br>
&gt;&gt; functionality are added (for both IPv4 and IPv6);<br>
&gt;&gt;<br>
&gt;&gt; --alex<br>
&gt; <br>
</blockquote></div>
</blockquote></div>



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic