buglwIP - A Lightweight TCP/IP stack - Bugs: bug #34682, Limit ARP request flood for...

 
 

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

bug #34682: Limit ARP request flood for unresolved entry

Submitter:  Amir Shalem <amirshalem>
Submitted:  Sat 29 Oct 2011 08:55:36 AM UTC
   
 
Category:  ARP Severity:  3 - Normal
Item Group:  Faulty Behaviour Status:  Fixed
Privacy:  Public Assigned to:  goldsimon
Open/Closed:  Closed Planned Release:  None
lwIP version:  CVS Head

Sat 22 Feb 2014 08:23:35 PM UTC, comment #4: 

Finally committed, thanks for the patch!

Simon Goldschmidt <goldsimon>
Group administrator
Thu 24 Nov 2011 08:40:40 PM UTC, comment #3: 

1. If etharp_request() there's nothing to do, it will be expired after timeout.

2. I would recommended not to wait for 1.5.0 for this patch, and push it now. Because without it, there's a possibility for an ARP request flood over the network.

Amir Shalem <amirshalem>
Tue 01 Nov 2011 01:03:37 PM UTC, comment #2: 

OK, that makes more sense, thank you. 

Could you add some code to handle the case where the call to etharp_request() in etharp_timer() fails?  It may be that no action is required here, in which case don't check the return code.

Simon: you outlined your preferred approach on bug34427 comment #2 some time ago, and this seems broadly in line with what you suggested.  Any objections?

Kieran Mansley <kieranm>
Group Member
Sat 29 Oct 2011 09:15:21 AM UTC, comment #1: 

I forgot to mention that the reason I included in my patch two changes:

1. Changing the ARP_TMR_INTERVAL, and fixing all other numbers values (ARP_AGE_REREQUEST_USED, ARP_MAXAGE, ARP_MAXPENDING)

2. Send arp_request() only for new entires, and in arp_tmr()

Is because I wish to maintain the behavior of sending ARP requests every second.
Before this patch this behavior happened because ARP request was sent for every SYN packet.
After this patch every SYN packet will be queue, and ARP request will be sent immediately after the first one, and afterwards it will be sent every second up to ARP_MAXPENDING (=10) seconds.

That's all.

Amir Shalem

Amir Shalem <amirshalem>
Sat 29 Oct 2011 08:55:36 AM UTC, original submission:  

If there's an unresolved entry (state=ETHARP_STATE_PENDING) this new code will avoid sending a ARP request for each packet.

It will be limited for ARP_MAXPENDING (=10) seconds, and ARP packet will be sent every ARP_TMR_INTERVAL (1 second).

When entry is unresolved (or expired after ARP_MAXAGE seconds), it wont ARP flood the network anymore.

Patch included, and tested with ARP_QUEUEING enabled and without it.

Amir Shalem

Amir Shalem <amirshalem>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attached Files
file #24238:  limit_arp_request_flood.patch added by amirshalem (5KiB - application/octet-stream - Limit ARP request flood)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by goldsimon (Posted a comment)
  • -email is unavailable- added by kieranm (Posted a comment)
  • -email is unavailable- added by amirshalem (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

     

    Follow 5 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2014-02-22 goldsimon StatusNone Fixed
        Assigned toNone goldsimon
        Open/ClosedOpen Closed
    2011-11-01 kieranm Planned Release 1.5.0
    2011-10-29 amirshalem Attached File- Added limit_arp_request_flood.patch, #24238

    Back to the top

    Powered by Savane 3.13-02a9.
    Corresponding source code