diff options
Diffstat (limited to 'avahi-core')
-rw-r--r-- | avahi-core/dns.c | 4 | ||||
-rw-r--r-- | avahi-core/entry.c | 5 | ||||
-rw-r--r-- | avahi-core/wide-area.c | 5 |
3 files changed, 11 insertions, 3 deletions
diff --git a/avahi-core/dns.c b/avahi-core/dns.c index e69b88a..2e1aa26 100644 --- a/avahi-core/dns.c +++ b/avahi-core/dns.c @@ -193,8 +193,8 @@ uint8_t* avahi_dns_packet_append_name(AvahiDnsPacket *p, const char *name) { if (!(t = (uint8_t*) avahi_dns_packet_extend(p, sizeof(uint16_t)))) return NULL; - t[0] = (uint8_t) ((0xC000 | idx) >> 8); - t[1] = (uint8_t) idx; + t[0] = (uint8_t) ((0xC000 | idx) >> 8); + t[1] = (uint8_t) idx; return saved_ptr; } } diff --git a/avahi-core/entry.c b/avahi-core/entry.c index 5db8908..3e25c69 100644 --- a/avahi-core/entry.c +++ b/avahi-core/entry.c @@ -225,6 +225,11 @@ static AvahiEntry * server_add_internal( /* may have to move lower into logic, for _new_ and _modified_ records only */ printf("+++ record of type %d named %s observed at entrypoint\n", r->key->type, r->key->name); + char[100] out; + int out_len = 100; + avahi_unescape_label("foo.com", 8, &out, &out_len); + printf("result: -%s-\n", out); + /* sketch publishing function */ /*wide_area_publish();*/ diff --git a/avahi-core/wide-area.c b/avahi-core/wide-area.c index b2d2084..6195a03 100644 --- a/avahi-core/wide-area.c +++ b/avahi-core/wide-area.c @@ -800,7 +800,10 @@ AvahiRecord* tsig_sign_packet(const char* keyname, const char* key, unsigned key return NULL; } - /*HMAC_Update(&ctx, <data/>, <length/>);*/ /*feed all the data to be hashed in */ + /*feed all the data to be hashed in */ + /*HMAC_Update(&ctx, <data/>, <length/>);*/ + HMAC_Update(&ctx, p->data, p->size); + /* HMAC_Update(&ctx, CONTINUE */ HMAC_Final(&ctx, keyed_hash, &hash_length); HMAC_cleanup(&ctx); |