Ticket #131 (closed defect: fixed)

Opened 3 years ago

Last modified 3 years ago

Publishing big dns records doesn't work

Reported by: sjoerd Owned by: lennart
Milestone: Avahi 0.6.18 Component: avahi-core
Keywords: Cc:

Description

To support Avatars in Link-local messaging (xep-0174) i need to publish quite large DNS NULL records. Unfortunatly that turned out to not work very wel.. Attached patch does the following:

* Places that create an dns packet of a certain size need to request an extra

AVAHI_DNS_PACKET_EXTRA_SIZE.. As dns_packet_new gives you that amount less then you asked for..

* No need to check if the estimate is > AVAHI_DNS_PACKET_SIZE_MAX. dns_packet_new does clamping * Fix a small bug when after all tries we still couldn't send a reply set reply to NULL to

prevent double frees

* If we made a reply packet of a specific size, send it out immediately.. Not doing this resulted

in an big loop making avahi spew packets on the network as fast as it can.. Although thanks to the other bugs i'm not sure this can every be triggers. If it can it's a security issue

* Bump AVAHI_DNS_PACKET_SIZE max a lot.. This is need to be able to publish avatars bigger then

about 9K

Attachments

big-record.patch (4.4 kB) - added by sjoerd 3 years ago.

Change History

Changed 3 years ago by sjoerd

Changed 3 years ago by lennart

  • status changed from new to closed
  • resolution set to fixed

(In [1405]) Fix registration of really large records, like it is necessary for XEP-0174 (jabber+bonjour) Based on an original patch by Sjoerd Simons, but heavily modified. (Closes #131)

Changed 3 years ago by lennart

  • milestone set to Avahi 0.6.18
Note: See TracTickets for help on using tickets.