From: Francis Dupont Date: Tue, 10 Dec 2019 09:43:31 +0000 (+0100) Subject: [#898] Changed received RFC 951 error message X-Git-Tag: tmark-perf-12-13-2019~11 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9e2efc3d0700a31e98aa09432f1c1553eab0e17e;p=thirdparty%2Fkea.git [#898] Changed received RFC 951 error message --- diff --git a/src/lib/dhcp/pkt4.cc b/src/lib/dhcp/pkt4.cc index 73fc04cbc2..b01ec7b665 100644 --- a/src/lib/dhcp/pkt4.cc +++ b/src/lib/dhcp/pkt4.cc @@ -1,4 +1,4 @@ -// Copyright (C) 2011-2017 Internet Systems Consortium, Inc. ("ISC") +// Copyright (C) 2011-2019 Internet Systems Consortium, Inc. ("ISC") // // This Source Code Form is subject to the terms of the Mozilla Public // License, v. 2.0. If a copy of the MPL was not distributed with this @@ -184,18 +184,18 @@ Pkt4::unpack() { if (buffer_in.getLength() == buffer_in.getPosition()) { // this is *NOT* DHCP packet. It does not have any DHCPv4 options. In // particular, it does not have magic cookie, a 4 byte sequence that - // differentiates between DHCP and BOOTP packets. - isc_throw(InvalidOperation, "Received BOOTP packet. BOOTP is not supported."); + // differentiates between DHCP and RFC 951 BOOTP packets. + isc_throw(InvalidOperation, "Received BOOTP packet without vendor information extensions."); } if (buffer_in.getLength() - buffer_in.getPosition() < 4) { - // there is not enough data to hold magic DHCP cookie - isc_throw(Unexpected, "Truncated or no DHCP packet."); + // there is not enough data to hold magic DHCP cookie + isc_throw(Unexpected, "Truncated or no DHCP packet."); } uint32_t magic = buffer_in.readUint32(); if (magic != DHCP_OPTIONS_COOKIE) { - isc_throw(Unexpected, "Invalid or missing DHCP magic cookie"); + isc_throw(Unexpected, "Invalid or missing DHCP magic cookie"); } size_t opts_len = buffer_in.getLength() - buffer_in.getPosition();