]> git.ipfire.org Git - thirdparty/ldns.git/commitdiff
* Fix to parse SVCB and HTTPS svcparam ech=0. develop
authorW.C.A. Wijngaards <wouter@nlnetlabs.nl>
Wed, 3 Jun 2026 12:21:06 +0000 (14:21 +0200)
committerW.C.A. Wijngaards <wouter@nlnetlabs.nl>
Wed, 3 Jun 2026 12:21:06 +0000 (14:21 +0200)
Changelog
str2host.c

index b32d92aca1ccb68ebd8e49de47ba4e7d48dcd6cb..841052c2ab45865fba807ae6bddd25393654ddec 100644 (file)
--- a/Changelog
+++ b/Changelog
@@ -8,6 +8,7 @@
          presentation format in ldns_pkt2str_fmt. Thanks Peter Kästle
        * The -O option to calculate (and sign) only the ZONEMD an input
          zone with ldns-signzone
+       * Fix to parse SVCB and HTTPS svcparam ech=0.
        
 1.9.0  2025-12-04
        * PR #246: Make ldns_calc_keytag() available for CDNSKEY RR
index 8a325921bc6eb88fdca7f3a9d3d87fe5d438bacf..f497bd8bdcca8b82da1c52f878c28136492a49d5 100644 (file)
@@ -2153,6 +2153,11 @@ parse_svcparam_ech(const char **s, uint8_t **dp, uint8_t *eod)
                *s += 1;
                quoted = true;
        }
+       if(**s == '0' && *(*s+1) == 0) {
+               /* single 0 represents empty buffer */
+               *s += 1;
+               return LDNS_STATUS_OK;
+       }
        b64_str = *s;
        while (isalnum((unsigned char)**s) || **s == '+'
                                           || **s == '/'