buglwIP - A Lightweight TCP/IP stack - Bugs: bug #64211, ICMP reply error when using bridge

 
 

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

bug #64211: ICMP reply error when using bridge

Submitter:  daniel.yang <ccnu>
Submitted:  Thu 18 May 2023 02:45:32 AM UTC
Votes: 1
 
Category:  IPv4 Severity:  3 - Normal
Item Group:  Faulty Behaviour Status:  Fixed
Privacy:  Public Assigned to:  goldsimon
Open/Closed:  Closed Planned Release:  2.2.1
lwIP version:  2.1.3

Wed 27 Sep 2023 07:49:52 PM UTC, comment #2: 

Fixed, thanks for reporting!

Simon Goldschmidt <goldsimon>
Group administrator
Thu 13 Jul 2023 03:45:51 PM UTC, comment #1: 

Problem still exist in 2.2-RC, see my duplicate (64423)

Cedric Berger <ceedriic>
Thu 18 May 2023 02:45:32 AM UTC, original submission:  

I may have a mistake because of my Inaccurate expression in bug #64145: ICMP reply error when using bridge.
Now i illustrate again.
when I use lwIP netif implementing an IEEE 802.1D MAC Bridge,I add two portif eth0 and eth1 ,also I set address and mac to bridge0 as host netif(192.168.1.5) when i set NULL address to portif eth0 and eth1.
I connected two devices to portif eth0 and eth1 in outside, the address are 192.168.1.6 and 192.168.1.7.
    But,when I ping host(192.168.1.5) from device(192.168.1.7),I get no reply.Then I debuged and found the issue point at function icmp_input(icmp.c#198) and bridgeif_send_to_port(bridgeif.c #257).
    In this case, icmp request from eth1(input pbuf->if_idx = netif->num + 1,here is 1,default is 0),but in function icmp_input,it reuse the input pbuf rather than alloc new one,so this pbuf->if_idx = netif->num + 1 = 1.Then function bridgeif_send_to_port use the pbuf->if_idx to prevent sending out to rx port(if (netif_get_index(portif) != p->if_idx)),at this time,icmp reply would never be forward to eth1,so icmp error.
    icmp replied success when I added statement(p->if_idx = 0) at icmp.c#248 before ip4_output_if.
You can see the network structure at file network structure.jpg.

daniel.yang <ccnu>

 

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

Attached Files
file #54756:  network@structure.jpg added by ccnu (50KiB - image/jpeg)

 

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 ceedriic (Posted a comment)
  • -email is unavailable- added by ceedriic (Voted in favor of this item)
  • -email is unavailable- added by ccnu (Submitted the item)
  •  

    There is 1 vote 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 6 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2023-09-27 goldsimon StatusNone Fixed
        Assigned toNone goldsimon
        Open/ClosedOpen Closed
        Planned ReleaseNone 2.2.1
    2023-07-13 ceedriic Carbon-Copy- Added ceedriic
    2023-05-18 ccnu Attached File- Added network@structure.jpg, #54756

    Back to the top

    Powered by Savane 3.13-54b4.
    Corresponding source code