Ticket #2422: IPv6 sin6_scope_id likely wrong?

Currently the IPv6 code always grabs the scope id associated with the NETWORK_INTERFACE as the scope ID used in bind, connect, and sendto. This is probably wrong. The scope ID finding code is in /src/condor_utils/ipv6_interface.cpp . It is used exclusively in /src/condor_utils/condor_sockfunc.cpp .

  1. What happens if NETWORK_INTERFACE=*?
  2. If both a global and link local address are present, what will sock_id be set to? Will it be correct for connections over global and link local?
  3. What if there are multiple link local addresses that are identical because of multiple network cards? (This will matter more if/when the scope ID code is extended to return an answer based on the IP address.)

May need to add support to specify scope id in IPv6 addresses.

[Append remarks]

Remarks:

2012-Mar-12 14:13:46 by adesmet:
Bonus points: if the IPv6 address isn't a local address, the scope id is (probably?) unnecessary.
[Append remarks]

Properties:

Type: defect           Last Change: 2012-Mar-12 14:13
Status: new          Created: 2011-Aug-25 14:40
Fixed Version:            Broken Version:  
Priority:          Subsystem:  
Assigned To: adesmet           Derived From: #9
Creator: adesmet  Rust:  
Customer Group: other  Visibility: public 
Notify:   Due Date:  

Related Check-ins:

2011-Aug-25 15:46   Check-in [26985]: CRUDE WORKAROUND for lack of getifaddrs on Windows. IPv6 WILL NOT WORK ON WINDOWS! Temporary step just so it compiles and I can confirm that IPv6 didn't break IPv4 on all platforms. A proper fix requires more thought, see #2422 for details. ===GT=== #2418 (By Alan De Smet )