]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
address off by one error in idn_output_filter
authorMark Andrews <marka@isc.org>
Tue, 17 Mar 2020 02:56:30 +0000 (13:56 +1100)
committerMark Andrews <marka@isc.org>
Tue, 17 Mar 2020 02:56:30 +0000 (13:56 +1100)
bin/dig/dighost.c

index 33841914714b0f3ac1027d94dea1136323d88a1a..85e725c030ac0df0b8c6e842ddfbcb1d61944dd8 100644 (file)
@@ -4420,7 +4420,7 @@ idn_output_filter(isc_buffer_t *buffer, unsigned int used_org) {
         * Copy name from 'buffer' to 'src' and terminate it with NULL.
         */
        srclen = isc_buffer_usedlength(buffer) - used_org;
-       if (srclen > sizeof(src)) {
+       if (srclen >= sizeof(src)) {
                warn("Input name too long to perform IDN conversion");
                return (ISC_R_SUCCESS);
        }