netdev
[Top] [All Lists]

multicast IP datagram forwarding bug and fix

To: <netdev@xxxxxxxxxxx>
Subject: multicast IP datagram forwarding bug and fix
From: "Weng, Wending" <WWending@xxxxxxxxxxx>
Date: Mon, 28 Jul 2003 13:20:31 -0400
Sender: netdev-bounce@xxxxxxxxxxx
Thread-index: AcNVKzM2n6nZ9yf3QoKw41OAI12Z9wAATw1w
Thread-topic: multicast IP datagram forwarding bug and fix
> Hi,
> 
>    LINUX doesn't forward multicast IP datagram if it has option(s), there is 
> is a bug in the module ipmr.c, function
> ipmr_forward_finish, below is the current version of this function:
> 
> static inline int ipmr_forward_finish(struct sk_buff *skb)
> {
>         struct dst_entry *dst = skb->dst;
> 
>         if (skb->len <= dst->pmtu)
>                 return dst->output(skb);
>         else
>                 return ip_fragment(skb, dst->output);
> }
> 
> it forgets to recalculate the checksum in case the option is modified.
> 
> The following code works properly:
> 
> static inline int ipmr_forward_finish(struct sk_buff *skb)
> {
>         struct dst_entry *dst = skb->dst;
> 
>         ip_forward_options (skb); /* this line recalculates checksum if 
> needed. */
> 
>         if (skb->len <= dst->pmtu)
>                 return dst->output(skb);
>         else
>                 return ip_fragment(skb, dst->output);
> }
> 
> Wending Weng


<Prev in Thread] Current Thread [Next in Thread>
  • multicast IP datagram forwarding bug and fix, Weng, Wending <=