Unbound 1.13.1rc1 pre-release

Hi,

Unbound 1.13.1 is available:
https://nlnetlabs.nl/downloads/unbound/unbound-1.13.1.tar.gz
sha256 8504d97b8fc5bd897345c95d116e0ee0ddf8c8ff99590ab2b4bd13278c9f50b8
pgp https://nlnetlabs.nl/downloads/unbound/unbound-1.13.1.tar.gz.asc

This release contains a number of bug fixes. There is added support
for the EDNS Padding option (RFC7830 and RFC8467), and the EDNS NSID
option (RFC 5001). Unbound control has added commands to enable and
disable rpz processing. Reply callbacks have a start time passed to
them that can be used to calculate time, these are callbacks for
response processing. With the option serve-original-ttl the TTL served
in responses is the original, not counted down, value, for when in
front of authority service.

Features
- Merge PR #375 by fhriley: Add rpz_enable and rpz_disable commands
  to unbound-control.
- Merge PR #391 from fhriley: Add start_time to reply callbacks so
  modules can compute the response time.
- Fix #397: [Feature request] add new type always_null to local-zone
  similar to always_nxdomain.
- Support for RFC5001: DNS Name Server Identifier (NSID) Option
  with the nsid: option in unbound.conf
- Padding of queries and responses with DNS over TLS as specified in
  RFC7830 and RFC8467.
- Merge PR #275 from Roland van Rijswijk-Deij: Add feature to return the
  original instead of a decrementing TTL ('serve-original-ttl')

Bug Fixes
- Fix #358: Squelch udp connect 'no route to host' errors on low
  verbosity.
- Fix #360: for the additionally reported TCP Fast Open makes TCP
  connections fail, in that case we print a hint that this is
  happening with the error in the logs.
- Fix #356: deadlock when listening tcp.
- Fix unbound-dnstap-socket to not use log routine from interrupt
  handler and not print so frequently when invoked in sequence.
- Fix on windows to ignore connection failure on UDP, unless verbose.
- make depend.
- Fix #371: unbound-control timeout when Unbound is not running.
- Fix to squelch permission denied and other errors from remote host,
  they are logged at higher verbosity but not on low verbosity.
- Merge PR #335 from fobser: Sprinkle in some static to prevent
  missing prototype warnings.
- Merge PR #373 from fobser: Warning: arithmetic on a pointer to void
  is a GNU extension.
- Fix missing prototypes in the code.
- Fix error cases when udp-connect is set and send() returns an error
  (modified patch from Xin Li @delphij).
- For #376: Fix that comm point event is not double removed or double
  added to event map.
- iana portlist updated.
- Fix #385: autoconf 2.70 impacts unbound build
- Fix #379: zone loading over HTTP appears to have buffer issues.
- Merge PR #395 from mptre: add missing null check.
- Fix #387: client-subnet-always-forward seems to effectively bypass
  any caching?
- For #391: use struct timeval* start_time for callback information.
- For #391: fix indentation.
- For #391: more double casts in python start time calculation.
- Add comment documentation.
- Fix clang analysis warning.
- Fix so local zone types always_nodata and always_deny can be used
  from the config file.
- Merge #399 from xiangbao227: The lock of lruhash table should
  unlocked after markdel entry.
- Fix for #93: dynlibmodule link fix for Windows.
- Fix for #93: dynlibmodule import library is named libunbound.dll.a.
- Merge #402 from fobser: Implement IPv4-Embedded addresses according
  to RFC6052.
- Fix #404: DNS query with small edns bufsize fail.
- Fix declaration before statement and signed comparison warning in
  dns64.
- Fix TTL of SOA record for negative answers (localzone and
  authzone data) to be the minimum of the SOA TTL and the SOA.MINIMUM.
- Fix compile of unbound-dnstap-socket without dnstap installed.
- Merge PR #355 from noloader: Make ICANN Update CA and DS Trust Anchor
  static data.
- Ignore cache blacklisting when trying to reply with expired data from
  cache (#394).
- Merge PR #408 from fobser: Prevent a few more yacc clashes.
- Annotate that we ignore the return value of if_indextoname.
- Fix to use correct type for label count in rpz routine.
- Fix empty clause warning in config_file nsid parse.
- Fix to use correct type for label count in ipdnametoaddr rpz routine.
- Fix empty clause warning in edns pass for padding.
- Fix for doxygen 1.8.20 compatibility.
- Attempt to fix NULL keys in the reuse_tcp tree; relates to #411.
- Fix dynlibmod link on rhel8 for -ldl inclusion.
- Fix windows dependency on libssp.dll because of default stack
  protector in mingw.
- Fix indentation of root anchor for use by windows install script.

Best regards, Wouter

Hi RayG,

We had a fix that may also solve the issue getting the rpz zonefile via url in windows (https://github.com/NLnetLabs/unbound/commit/bc4bdbabeab1388e41ce64714203b4fd3fab18be).

I have prepared the following for you to try on windows:
https://nlnetlabs.nl/~george/unbound_setup_1.13.2_20210222.exe
https://nlnetlabs.nl/~george/unbound-1.13.2_20210222.zip

Let me know how it goes,
-- George

Hi George,

Thanks for the update...

I have installed that version and there is a warning in the log file after starting.

Is there any other information you require?

This is an entry in the URLHaus RPZ file which is not in my other list of excluded DNS names which does NOT return NXDOMAIN and the log file does not show any RPZ logging? It is still returning an IP address. So I deduce things are not working as expected.

C:\>dig a9ashop.com

; <<>> DiG 9.16.12 <<>> a9ashop.com
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 54145
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 1232
;; QUESTION SECTION:
;a9ashop.com. IN A

;; ANSWER SECTION:
a9ashop.com. 1799 IN A 162.241.124.73

;; Query time: 140 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Mon Feb 22 15:23:10 GMT Standard Time 2021
;; MSG SIZE rcvd: 56
C:\>

There is also no zonefile created.

     rpz: # MyResponsePolicyZones.conf
     name: "URLHaus"
     zonefile: "C:\ProgramData\Unbound\Logs\urlhaus.zone"
     url: "https://urlhaus.abuse.ch/downloads/rpz/&quot;
     rpz-log: yes
     rpz-log-name: "URLHausRPZ"
     rpz-action-override: nxdomain

I hope the attached files help

RayG

(attachments)

URLHaus_NetworkTrace_20210222.ncf (25.6 KB)
URLHaus_NetworkTrace_20210222.txt (504 KB)
unbound_2021-02-21-14-12-19.log (36.1 KB)

Hi RayG,

The log did help.
You hit a bug for an upcoming feature that verifies a zone before loading.

You can find the fixed files at:
https://nlnetlabs.nl/~george/unbound_setup_1.13.2_20210222_A.exe
https://nlnetlabs.nl/~george/unbound-1.13.2_20210222_A.zip

Additionally, using:
  domain-insecure: "URLHaus."
or
  zonemd-permissive-mode: yes
in the configuration should also bypass the issue.

-- George

Hi George,

OK I have installed the updated file below and tried unbound, it starts OK but I still see the

23/02/2021 15:10:24 C:\Program Files\Unbound\unbound.exe[18376:0] warning: auth zone URLHaus.: ZONEMD verification failed: verify DNSKEY RRset with trust anchor failed

I have both of these lines in the configuration is that correct?

Hi RayG,

This was another bug in relation to the upcoming feature and the config options I suggested. Should be fixed now.

But let's not get distracted by the zonemd code.

I have prepared the following which is 1.13.1 with just the fix for http read (no new functionality added):
https://nlnetlabs.nl/~george/unbound_setup_1.13.1_20210224.exe
https://nlnetlabs.nl/~george/unbound-1.13.1_20210224.zip

Please give it a try.

-- George

Hi George,

OK its installed and running but its still returning an IP address for an entry in the URLHaus list.

alemelektronik.com CNAME . ; Malware download (2020-10-21), see URLhaus | Checking your browser

C:\>dig alemelektronik.com

; <<>> DiG 9.16.12 <<>> alemelektronik.com
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 59310
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 1232
;; QUESTION SECTION:
;alemelektronik.com. IN A

;; ANSWER SECTION:
alemelektronik.com. 3600 IN A 185.126.176.84

;; Query time: 203 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Wed Feb 24 14:14:53 GMT Standard Time 2021
;; MSG SIZE rcvd: 63

C:\>

RayG

(attachments)

unbound_2021-02-24-12-17-44.log (23.5 KB)