JDK-4742177 : Re-test IPv6 (and specifically MulticastSocket) with latest Linux & USAGI code
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.net
  • Affected Version: 1.4.0,1.4.1,5.0,6
  • Priority: P4
  • Status: Closed
  • Resolution: Fixed
  • OS:
    generic,linux,linux_redhat_4.0,linux_redhat_8.0,solaris_9 generic,linux,linux_redhat_4.0,linux_redhat_8.0,solaris_9
  • CPU: generic,x86,sparc
  • Submitted: 2002-09-05
  • Updated: 2015-08-25
  • Resolved: 2009-12-24
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 6 JDK 7
6u18Fixed 7 b16Fixed
Related Reports
Duplicate :  
Duplicate :  
Duplicate :  
Duplicate :  
Relates :  
Relates :  
Relates :  
Description
This bug is to remind us to schedule time to test IPv6 (esp. 
multicasting) with the latest Linux distributions and USAGI snapshots.

Some specific items to test are :-

- IPV6_MULTICAST_IF sets the outgoing interface for IPv6 multicats 
but appears not to set the outgoing interface for IPv4 multicasts
sent from same socket. A similiar issues needs to be examined
for the outgoing ttl set via IPV6_MULTICAST_HOPS.

- SO_REUSEADDR behaviour has gone through a number of iterations in
the USAGI snapshots - we need to check the ability to bind multiple
UDP sockets to the same port is still okay.

- IPV6ONLY socket options is now implemented - need to check
default behaviour and specifically that !IPV6ONLY still implies a
unified port space.

- USAGI appears to have implemented the RFCs dealing with IPv6 
source address selection. This means that we should be able to
test sending of multicasts with scopes greater than the scope 
of any local address. 

- SuSE 8.0 apparently ships with 2.4.16 kernel with experimental
IPv6 enabled. At least one developer has observed IPv4 multicasting to
stop working with this distribution (-Djava.net.preferIPv4Stack=true
works okay). This is likely to be a SuSE configuration issue as 
2.4.16+IPv6 works with RedHat.

- On current distributions !IPV6_MULTICAST_LOOP isn't preventing
the loopback of IPv4 multicast packets.

- getaddrinfo doesn't reject many invalid IPv6 addresses - need
to check latest USAGI changes to see if this has been addressed.

- We have dependencies on the /proc file system to enumerate
IPv6 interfaces and additionally we need access to the IPv6 
routing table to select outgoing interfaces when the destination
is a link-local address. We need to check that the format hasn't 
changed. 

- Linux/gcc's header files define the sockaddr_in6 structure
incorrectly (missing the sin6_scope_id field) so we are forced
to use our own definition. Need to check for any updates to this 
(esp with the tentative move to gcc3.x).

###@###.### 2002-09-05

Comments
EVALUATION Same for loopback mode. On Linux, IP_MULTICAST_LOOP only enable/disable loopback mode for IPv4 multicast groups, while IPV6_MULTICAST_LOOP sets loopback mode for IPv6 multicast groups. We need to set both of them for Linux if IPv6 is available. Attach the test code.
2007-06-08

EVALUATION IPV6_MULTICAST_IF only sets outgoing interface for ipv6 multicast packet, while IP_MULTICAST_IF sets outgoing interface for ipv4 and ipv4-mapped ipv6 multicat packet. Test code attached.
2007-01-17

EVALUATION IPV6_MULTICAST_HOPS only sets the hop limit for ipv6 multicast packet, while IP_MULTICAST_TTL sets the ttl for ipv4 and ipv4-mapped multicast packet. Test code attached. Run it like: hop_limit_test -4 239.255.1.2 8888 hop_limit_test -6 239.255.1.2 8888 hop_limit_test -4 ff01::1 8888 hop_limit_test -6 ff01::1 8888 hop_limit_test -4 ::ffff:239.255.1.2 8888 hop_limit_test -6 ::ffff:239.255.1.2 8888
2007-01-15

EVALUATION By default IPV6_V6ONLY option is off. And Linux has separate port space now.
2007-01-12

EVALUATION SO_REUSEADDR works also.
2007-01-12

EVALUATION Test 27 invlid IPv6 address on a 2.6 linux box. getaddrinfo rejects them all. Test code attached.
2007-01-10