diff --git a/sys/src/cmd/ndb/convDNS2M.c b/sys/src/cmd/ndb/convDNS2M.c index 7442a5802..30e8ca9be 100644 --- a/sys/src/cmd/ndb/convDNS2M.c +++ b/sys/src/cmd/ndb/convDNS2M.c @@ -275,6 +275,7 @@ convRR2M(RR *rp, uchar *p, uchar *ep, Dict *dp) NAME(rp->rmb->name); NAME(rp->rp->name); break; + case Tdnskey: case Tkey: USHORT(rp->key->flags); UCHAR(rp->key->proto); diff --git a/sys/src/cmd/ndb/convM2DNS.c b/sys/src/cmd/ndb/convM2DNS.c index 8d35bbddb..31b4c47f4 100644 --- a/sys/src/cmd/ndb/convM2DNS.c +++ b/sys/src/cmd/ndb/convM2DNS.c @@ -448,6 +448,7 @@ retry: rp->rmb = dnlookup(NAME(dname), Cin, 1); rp->rp = dnlookup(NAME(dname), Cin, 1); break; + case Tdnskey: case Tkey: USHORT(rp->key->flags); UCHAR(rp->key->proto); diff --git a/sys/src/cmd/ndb/dn.c b/sys/src/cmd/ndb/dn.c index 5a789925f..e52cad3ff 100644 --- a/sys/src/cmd/ndb/dn.c +++ b/sys/src/cmd/ndb/dn.c @@ -893,6 +893,7 @@ rrcopy(RR *rp, RR **last) nrp->srv = srv; *srv = *rp->srv; break; + case Tdnskey: case Tkey: key = nrp->key; *nrp = *rp; @@ -1273,6 +1274,7 @@ rrfmt(Fmt *f) case Trp: fmtprint(&fstr, "\t%s %s", dnname(rp->rmb), dnname(rp->rp)); break; + case Tdnskey: case Tkey: if (rp->key == nil) fmtprint(&fstr, "\t "); @@ -1413,6 +1415,7 @@ rravfmt(Fmt *f) idnname(rp->rmb, buf, sizeof(buf)), idnname(rp->rp, buf, sizeof(buf))); break; + case Tdnskey: case Tkey: if (rp->key == nil) fmtprint(&fstr, " flags= proto= alg="); @@ -1951,6 +1954,7 @@ rralloc(int type) rp->srv = emalloc(sizeof(*rp->srv)); setmalloctag(rp->srv, rp->pc); break; + case Tdnskey: case Tkey: rp->key = emalloc(sizeof(*rp->key)); setmalloctag(rp->key, rp->pc); @@ -1994,6 +1998,7 @@ rrfree(RR *rp) memset(rp->srv, 0, sizeof *rp->srv); /* cause trouble */ free(rp->srv); break; + case Tdnskey: case Tkey: free(rp->key->data); memset(rp->key, 0, sizeof *rp->key); /* cause trouble */