summaryrefslogtreecommitdiffstats
path: root/avahi-core/dns.c
diff options
context:
space:
mode:
Diffstat (limited to 'avahi-core/dns.c')
-rw-r--r--avahi-core/dns.c28
1 files changed, 28 insertions, 0 deletions
diff --git a/avahi-core/dns.c b/avahi-core/dns.c
index 9312502..6cd876a 100644
--- a/avahi-core/dns.c
+++ b/avahi-core/dns.c
@@ -763,6 +763,34 @@ static int append_rdata(AvahiDnsPacket *p, AvahiRecord *r) {
break;
case AVAHI_DNS_TYPE_TSIG:
+
+ if (!(avahi_dns_packet_append_name(p, r->data.tsig.algorithm_name)))
+ return -1;
+
+ if (!avahi_dns_packet_append_bytes(p, r->data.tsig.time_signed, 6)) /* 6 bytes. Order may need fixing? */
+ return -1;
+
+ if (!avahi_dns_packet_append_bytes(p, &r->data.tsig.fudge, sizeof(r->data.tsig.fudge)))
+ return -1;
+
+ if (!avahi_dns_packet_append_bytes(p, &r->data.tsig.mac_size, sizeof(r->data.tsig.mac_size)))
+ return -1;
+
+ if (!avahi_dns_packet_append_bytes(p, &r->data.tsig.mac, r->data.tsig.mac_size))
+ return -1;
+
+ if (!avahi_dns_packet_append_bytes(p, &r->data.tsig.original_id, sizeof(r->data.tsig.original_id)))
+ return -1;
+
+ if (!avahi_dns_packet_append_bytes(p, &r->data.tsig.error, sizeof(r->data.tsig.error)))
+ return -1;
+
+ if (!avahi_dns_packet_append_bytes(p, &r->data.tsig.other_len, sizeof(r->data.tsig.other_len)))
+ return -1;
+
+ if (!avahi_dns_packet_append_bytes(p, &r->data.tsig.other_data, r->data.tsig.other_len))
+ return -1;
+
break;
default: