Commit Diff
Diff:
51d4b969a71d3d1c3ecf5619b4e4b9f507e3b2a6
a76d851f20fb397eacb1d2b5d1f2b6a3a7ce0e36
Commit:
a76d851f20fb397eacb1d2b5d1f2b6a3a7ce0e36
Tree:
f865f64e4c4ac05c53877c1a9448c96b825e7941
Author:
pjp <pjp@delphinusdns.org>
Committer:
pjp <pjp@delphinusdns.org>
Date:
Fri Feb 15 19:46:58 2019 UTC
Message:
fix nsec3 return types, and fix ttl in sshfp parsing.
blob - 9235cfdfd4f5b2c6189db5b8e58ba0b84197571a
blob + 4551229264aa8574990b12c427a9bd95de02682e
--- ddd-db.h
+++ ddd-db.h
@@ -27,7 +27,7 @@
*/
/*
- * $Id: ddd-db.h,v 1.13 2019/02/15 15:11:34 pjp Exp $
+ * $Id: ddd-db.h,v 1.14 2019/02/15 19:46:58 pjp Exp $
*/
#ifndef _DB_H
@@ -324,7 +324,7 @@ struct node {
struct rrtab {
char *name;
u_int16_t type;
- int16_t internal_type;
+ u_int16_t internal_type;
};
blob - 7113c143024ae4340cc787d10a40ccbd850905f3
blob + 9b1fd4b2ff580caa992f492f7291ad200a236225
--- parse.y
+++ parse.y
@@ -21,7 +21,7 @@
*/
/*
- * $Id: parse.y,v 1.59 2019/02/15 15:11:34 pjp Exp $
+ * $Id: parse.y,v 1.60 2019/02/15 19:46:58 pjp Exp $
*/
%{
@@ -2590,6 +2590,7 @@ fill_sshfp(char *name, char *type, int myttl, int alg,
p += 2;
}
+ sshfp->ttl = myttl;
rbt = create_rr(db, converted_name, converted_namelen, DNS_TYPE_SSHFP, sshfp);
if (rbt == NULL) {
blob - 2d2e3e8c0b3481092b7b6631f6df7947834b2479
blob + f9236051ebbc54dee4f4223ea28f2f0bab17a2bd
--- reply.c
+++ reply.c
@@ -27,7 +27,7 @@
*/
/*
- * $Id: reply.c,v 1.66 2019/02/15 18:47:43 pjp Exp $
+ * $Id: reply.c,v 1.67 2019/02/15 19:46:58 pjp Exp $
*/
#include "ddd-include.h"
@@ -54,7 +54,6 @@ extern struct rbtree * lookup_zone(ddDB *, struct que
extern void slave_shutdown(void);
extern int get_record_size(ddDB *, char *, int);
extern char * dns_label(char *, int *);
-extern int lookup_type(int internal_type);
extern struct rbtree * find_rrset(ddDB *db, char *name, int len);
extern struct rrset * find_rr(struct rbtree *rbt, u_int16_t rrtype);
@@ -5197,10 +5196,10 @@ create_anyreply(struct sreply *sreply, char *reply, in
offset += ((struct nsec3 *)rrp->rdata)->nextlen;
- memcpy(&reply[offset], &((struct nsec *)rrp->rdata)->bitmap,
- ((struct nsec *)rrp->rdata)->bitmap_len);
+ memcpy(&reply[offset], &((struct nsec3 *)rrp->rdata)->bitmap,
+ ((struct nsec3 *)rrp->rdata)->bitmap_len);
- offset += ((struct nsec *)rrp->rdata)->bitmap_len;
+ offset += ((struct nsec3 *)rrp->rdata)->bitmap_len;
answer->rdlength = htons(&reply[offset] - answer->rdata);
blob - 7c189a77ef4dce8e22bbac508a55d3ebafa02159
blob + 41ea3517145bae8d4941f1e5b00510c41f106bda
--- util.c
+++ util.c
@@ -27,7 +27,7 @@
*/
/*
- * $Id: util.c,v 1.17 2019/02/15 15:11:34 pjp Exp $
+ * $Id: util.c,v 1.18 2019/02/15 19:46:58 pjp Exp $
*/
#include "ddd-include.h"
@@ -96,7 +96,7 @@ struct rrtab myrrtab[] = {
{ "a", DNS_TYPE_A, DNS_TYPE_A } ,
{ "aaaa", DNS_TYPE_AAAA, DNS_TYPE_AAAA },
{ "cname", DNS_TYPE_CNAME, DNS_TYPE_CNAME },
- { "delegate", DNS_TYPE_DELEGATE, DNS_TYPE_NS },
+ { "delegate", DNS_TYPE_NS, DNS_TYPE_NS },
{ "dnskey", DNS_TYPE_DNSKEY, DNS_TYPE_DNSKEY },
{ "ds", DNS_TYPE_DS, DNS_TYPE_DS },
{ "hint", DNS_TYPE_HINT, DNS_TYPE_NS },
repomaster@centroid.eu