From: Remi Gacogne Date: Mon, 29 Aug 2016 13:50:44 +0000 (+0200) Subject: auth: Fix a stack-based off-by-one write in the HTTP remote backend X-Git-Tag: dnsdist-1.1.0-beta2~87^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F4544%2Fhead;p=thirdparty%2Fpdns.git auth: Fix a stack-based off-by-one write in the HTTP remote backend Reported by mongo (thanks!). --- diff --git a/modules/remotebackend/httpconnector.cc b/modules/remotebackend/httpconnector.cc index 5b1cd1c1b2..bdafa3a80c 100644 --- a/modules/remotebackend/httpconnector.cc +++ b/modules/remotebackend/httpconnector.cc @@ -397,7 +397,6 @@ int HTTPConnector::recv_message(Json& output) { throw NetworkError("EOF while reading"); if (rd<0) throw NetworkError(std::string(strerror(rd))); - buffer[rd] = 0; arl.feed(std::string(buffer, rd)); } // timeout occured.