buglwIP - A Lightweight TCP/IP stack - Bugs: bug #49648, Always check whether netif_default...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #49648: Always check whether netif_default is NULL

Submitted by:  David van Moolenbroek <dcvmoole>
Submitted on:  Fri 18 Nov 2016 10:43:13 PM UTC  
 
Category: NoneSeverity: 3 - Normal
Item Group: Crash ErrorStatus: Fixed
Privacy: PublicAssigned to: None
Open/Closed: ClosedPlanned Release: None
lwIP version: git head

Mon 21 Nov 2016 09:19:02 AM UTC, comment #1:

Thanks for the fixes!

Dirk Ziegelmeier <dziegel>
Project Member
Fri 18 Nov 2016 10:43:13 PM UTC, original submission:

There may be cases where there is no default interface, for example when a real interface has not (yet) been configured. I ran into a crash while attempting to route a link-local address on a loopback device in that situation. Attached patch should resolve that.

(I'm not sure whether to file these things as bugs or patches by the way..)

===

In general, netif_default may be NULL, and various places in the code already check for this case before attempting to dereference the netif_default pointer. Some places do not perform this check though, and may cause null pointer dereferences if netif_default is not set. This patch adds NULL checks to those places as well.

David van Moolenbroek <dcvmoole>

 

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by dziegel (Posted a comment)
  • -unavailable- added by dcvmoole (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 3 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Mon 21 Nov 2016 09:19:02 AM UTCdziegelStatusNone=>Fixed
      Open/ClosedOpen=>Closed
    Fri 18 Nov 2016 10:43:13 PM UTCdcvmooleAttached File-=>Added 0001-Always-check-whether-netif_default-is-NULL.patch, #39014

    Back to the top


    Powered by Savane 3.1-cleanup1