From af67acc0d076fa4f767644a71c9cd9ad9bc56b89 Mon Sep 17 00:00:00 2001 From: Mark Andrews Date: Tue, 17 Mar 2020 13:56:30 +1100 Subject: [PATCH] address off by one error in idn_output_filter --- bin/dig/dighost.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/dig/dighost.c b/bin/dig/dighost.c index 3384191471..85e725c030 100644 --- a/bin/dig/dighost.c +++ b/bin/dig/dighost.c @@ -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); }