United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-6633549 (dc) Include-mode filtering of IPv6 sources does not block datagrams on Linux
JDK-6633549 : (dc) Include-mode filtering of IPv6 sources does not block datagrams on Linux

Details
Type:
Bug
Submit Date:
2007-11-23
Status:
Closed
Updated Date:
2013-06-26
Project Name:
JDK
Resolved Date:
2012-08-20
Component:
core-libs
OS:
generic
Sub-Component:
java.nio
CPU:
generic
Priority:
P4
Resolution:
Fixed
Affected Versions:
7
Fixed Versions:

Related Reports
Backport:
Backport:

Sub Tasks

Description
This bug is for tracking purposes and is believed to be a bug in the Linux IPv6 stack.

The failure duplicates on Ubuntu with 2.6.17-10 kernel and this test;
    test/java/nio/channels/DatagramChannel/MulticastSendReceiveTests.java 

On this kernel, IPv4 include-mode and exclude-mode filtering works correctly. With IPv6 then exclude-mode filtering works okay, but include-mode doesn't work.


$ java MulticastSendReceiveTests
create channel to INET socket
join 225.4.5.6 @ eth0
Send message from 129.156.232.195 -> group 225.4.5.6
Waiting to receive message
Message received from 129.156.232.195
block 129.156.232.195
Send message from 129.156.232.195 -> group 225.4.5.6
Waiting to receive message
No message received (correct)
unblock 129.156.232.195
Send message from 129.156.232.195 -> group 225.4.5.6
Waiting to receive message
Message received from 129.156.232.195
join 225.4.5.6 @ eth0 only-source 1.2.3.4
Send message from 129.156.232.195 -> group 225.4.5.6
Waiting to receive message
No message received (correct)
join 225.4.5.6 @ eth0 only-source 129.156.232.195
Send message from 129.156.232.195 -> group 225.4.5.6
Waiting to receive message
Message received from 129.156.232.195
create channel to INET6 socket
join ff02:0:0:0:0:0:0:a @ eth0
Send message from fe80:0:0:0:206:5bff:fe75:37c3%2 -> group ff02:0:0:0:0:0:0:a
Waiting to receive message
Message received from fe80:0:0:0:206:5bff:fe75:37c3%2
block fe80:0:0:0:206:5bff:fe75:37c3%2
Send message from fe80:0:0:0:206:5bff:fe75:37c3%2 -> group ff02:0:0:0:0:0:0:a
Waiting to receive message
No message received (correct)
unblock fe80:0:0:0:206:5bff:fe75:37c3%2
Send message from fe80:0:0:0:206:5bff:fe75:37c3%2 -> group ff02:0:0:0:0:0:0:a
Waiting to receive message
Message received from fe80:0:0:0:206:5bff:fe75:37c3%2
join ff02:0:0:0:0:0:0:a @ eth0 only-source fe80:0:0:0:0:0:0:1234
Send message from fe80:0:0:0:206:5bff:fe75:37c3%2 -> group ff02:0:0:0:0:0:0:a
Waiting to receive message
Message received from fe80:0:0:0:206:5bff:fe75:37c3%2
Exception in thread "main" java.lang.RuntimeException: Message not expected
        at MulticastSendReceiveTests.receiveDatagram(MulticastSendReceiveTests.java:101)
        at MulticastSendReceiveTests.test(MulticastSendReceiveTests.java:179)
        at MulticastSendReceiveTests.main(MulticastSendReceiveTests.java:210)

                                    

Comments
EVALUATION

This appears to be an issue with the definitions in Net.c.
                                     
2010-08-16
EVALUATION

http://hg.openjdk.java.net/hsx/hotspot-comp/jdk/rev/11d5ddc6a6d4
                                     
2012-08-14



Hardware and Software, Engineered to Work Together