[avahi] Only getting link-local IPv6 addresses with 0.6.16 on FreeBSD 5.4

Lennart Poettering lennart at poettering.net
Sun Feb 4 09:10:11 PST 2007


On Sun, 14.01.07 09:44, Bill Trost (trost at cloud.rain.com) wrote:

Hi!

I am sorry for the late response!

> Aargh! I just started setting up avahi so my Linux laptop could find my FreeBSD
> desktop via IPv6. After much circuitation, I get the impression that avahi is
> publishing the wrong IPv6 addresses under FreeBSD. To wit, if I browse the existing
> v6 addresses, I see

The reason for this wrong behaviour can be found in line 201 of avahi-core/iface-pfroute.c:

http://avahi.org/browser/trunk/avahi-core/iface-pfroute.c#L201

The Linux kernel assigns a configurable scope to each IP address which
we use to choose the proper IP address to publish. Apparently FreeBSD
doesn't have that. The current code in Avahi thus assumes global scope
for all addresses. 

A workaround for FreeBSD might be to check the address prefix directly
and to set global_scope to 1 only if it isn't fe80:: or 169.254. (Explanation:
global_scope is a boolean which for each address should be 1 if the
address is "global", and 0 if it is "link-local").

Patches welcome!

Lennart

-- 
Lennart Poettering; lennart [at] poettering [dot] net
ICQ# 11060553; GPG 0x1A015CC4; http://0pointer.net/lennart/


More information about the avahi mailing list