diff --git a/Makefile.in b/Makefile.in index ee6b86bb..180fc2c5 100644 --- a/Makefile.in +++ b/Makefile.in @@ -165,7 +165,7 @@ distclean: rm -f m4/ltoptions.m4 rm -f m4/ltsugar.m4 rm -f m4/ltversion.m4 - rm -f $(distdir).tar.gz $(distdir).tar.gz.sha256 + rm -f $(distdir).tar.gz $(distdir).tar.gz.sha256 $(distdir).tar.gz.sha1 rm -f $(distdir).tar.gz.md5 $(distdir).tar.gz.asc megaclean: @@ -177,11 +177,14 @@ autoclean: megaclean dist: $(distdir).tar.gz -pub: $(distdir).tar.gz.sha256 $(distdir).tar.gz.md5 $(distdir).tar.gz.asc +pub: $(distdir).tar.gz.sha256 $(distdir).tar.gz.md5 $(distdir).tar.gz.asc $(distdir).tar.gz.sha1 $(distdir).tar.gz.sha256: $(distdir).tar.gz openssl sha256 $(distdir).tar.gz >$@ +$(distdir).tar.gz.sha1: $(distdir).tar.gz + openssl sha1 $(distdir).tar.gz >$@ + $(distdir).tar.gz.md5: $(distdir).tar.gz openssl md5 $(distdir).tar.gz >$@ diff --git a/src/context.c b/src/context.c index aaea6d59..d952d8d6 100644 --- a/src/context.c +++ b/src/context.c @@ -5349,6 +5349,8 @@ int _getdns_context_write_priv_file(getdns_context *context, (void) close(fd); context->can_write_appdata = PROP_UNABLE; + context->trust_anchors_backoff_expiry = + _getdns_get_now_ms() + context->trust_anchors_backoff_time; return 0; } @@ -5361,9 +5363,12 @@ int _getdns_context_can_write_appdata(getdns_context *context) if (context->can_write_appdata == PROP_ABLE) return 1; - else if (context->can_write_appdata == PROP_UNABLE) - return 0; - + else if (context->can_write_appdata == PROP_UNABLE) { + if (_getdns_ms_until_expiry( + context->trust_anchors_backoff_expiry) > 0) + return 0; + context->can_write_appdata = PROP_UNKNOWN; + } (void) snprintf( test_fn, sizeof(test_fn) , "write-test-%d.tmp", arc4random());