<div dir="ltr">Hi Rob, list,<div><br></div><div>dhcp client had a segfault, when DHCP message contained 'pad' option.</div><div><br></div><div>The parsing logic kept checking for other options beyond __pad__ option, without</div>
<div>checking if it was __end__ option after that or not.</div><div><br></div><div><div>--- a/toys/pending/dhcp.c<span class="" style="white-space:pre"> </span>2014-05-14 06:15:01.000000000 +0530</div><div>+++ b/toys/pending/dhcp.c<span class="" style="white-space:pre"> </span>2014-05-21 14:11:22.396020084 +0530</div>
<div>@@ -1101,7 +1101,10 @@</div><div> }</div><div> </div><div> while (*optptr != DHCP_OPTION_END) {</div><div>- while (*optptr == DHCP_OPTION_PADDING) optptr++;</div><div>+ if (*optptr == DHCP_OPTION_PADDING) {</div>
<div>+ optptr++;</div><div>+ continue;</div><div>+ }</div><div> if (*optptr == DHCP_OPTION_OVERLOAD) {</div><div> overloaded = optptr[2];</div><div> optptr += optptr[1] + 2;</div></div><div><br>
</div><div>Please apply the attched fix patch to dhcp.c</div><div><br></div><div>regards,</div><div>Ashwini</div></div>