[avahi] Strange MDNS response from Axis cameras

Sebastien Estienne sebastien.estienne at gmail.com
Fri Feb 10 03:11:57 PST 2006


On 2/10/06, Iván Sánchez Ortega <i.sanchez at mirame.net> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> El Viernes 10 de Febrero de 2006 02:17, Lennart Poettering escribió:
> > I wonder if we should add some logic to always prefer real addresses
> > over ipv4ll if we recieve both when browsing for them. Would make some
> > sense, I guess.
>
> Yes but, as Marc pointed out, all Axis cameras come with the default static IP
> (192.168.0.90 IIRC), and I would expect this behaviour from other embedded
> devices as well.
>
> So, IMHO the algorithm to decide whether to choose the static or the
> link-local address from a pool of addresses should be intelligent enough to:
> - - Discard non locally routable addresses.
> - - Detect potential IP address conflicts (two or more devices announcing the
> same IP).

Or we could return all the detected IP (in one way or another) and of
a new function in our Api that would check if the ip is "reachable" or
not.

Now how to return more than one address (hopefully without modifying
the current api)?
Maybe we could emit one more callback per IP found? (I don't know yet
if we could modify AvahiAddress to be able to handle more than one
adress without breaking the Api compatibility.)

And this behaviour could be control with AvahiLookupFlags when calling
avahi_s_service_resolver_new.
We could decide:
- return only the first adress found
- return only linklocal address
- return all address found

We could also add a "AVAHI_LOOKUP_RESULT_MULTI" to
AvahiLookupResultFlags, so we could know that the resolve query
returned more than one address.

>
> I agree with Marc: link-local addresses (169.254.0.0) are preferible than
> static addresses.
>
> But it seems a good idea to me to choose the static IP, only if I can't route
> traffic to 169.254.0.0.
>
> Or, avahi could add the relevant entry to the routing table (if there isn't
> already a way to route traffic to link-local addresses), in order to comply
> with RFC 3927*. This way, after I run avahi-browser (or whatever), I could
> automagically use services on devices with a link-local address.
>
> I think this approach is simpler, but I don't know if it can be easily done,
> or secure enough.
>

I'm not sure that doing this is the job of the avahi daemon, in my
opinion it should be handled by the network scripts of the linux
distribution.

>
> *
> route add -net 169.254.0.0 netmask 255.255.0.0 dev eth0 metric 99
> route add default dev eth0 metric 99
> - --
> - ----------------------------------
> Iván Sánchez Ortega <ivansanchez at escomposlinux.org> <i.sanchez at mirame.net>
>
> "If you haven't got anything nice to say about anybody, come sit next to me."
>  - Alice Roosevelt Longworth (1884-1980)
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.2 (GNU/Linux)
>
> iD8DBQFD7GLb3jcQ2mg3Pc8RApyzAJ9xCiHib7BJvq3gBJSRT6U2Rx9kWgCfdoh5
> bkhOsONptP7LuArlnY13eUA=
> =Qf6v
> -----END PGP SIGNATURE-----
> _______________________________________________
> avahi mailing list
> avahi at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/avahi
>


--
Sebastien Estienne


More information about the avahi mailing list