summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Schanzenbach <mschanzenbach@posteo.de>2020-06-28 22:38:45 +0200
committerMartin Schanzenbach <mschanzenbach@posteo.de>2020-06-28 22:38:45 +0200
commit8c2243f05b4aa671cdcd4cfd614055ef6f80e20c (patch)
tree35047cdef52781e34cedc68d2d524f5b6020f5d8
parent686a873aed44e0dff36f0d52c465af2e5efb5ab2 (diff)
Prevent user from storing records which belong in a BOX
-rw-r--r--src/namestore/gnunet-namestore.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/namestore/gnunet-namestore.c b/src/namestore/gnunet-namestore.c
index 94fcb8952..1e0c6fdbc 100644
--- a/src/namestore/gnunet-namestore.c
+++ b/src/namestore/gnunet-namestore.c
@@ -1087,6 +1087,16 @@ run_with_zone_pkey (const struct GNUNET_CONFIGURATION_Handle *cfg)
ret = 1;
return;
}
+ if ((GNUNET_DNSPARSER_TYPE_SRV == type) ||
+ (GNUNET_DNSPARSER_TYPE_TLSA == type) ||
+ (GNUNET_DNSPARSER_TYPE_OPENPGPKEY == type))
+ {
+ fprintf (stderr,
+ _ ("For DNS record types `SRV', `TLSA' and `OPENPGPKEY'"));
+ fprintf (stderr, ", please use a `BOX' record instead\n");
+ ret = 1;
+ return;
+ }
if (NULL == value)
{
fprintf (stderr,