* IPv6 : ICMPV6_DEST_UNREACH type with ICMPV6_NOROUTE code
@ 2003-05-06 10:18 Seong Moon
2003-05-09 11:34 ` Robert Olsson
0 siblings, 1 reply; 4+ messages in thread
From: Seong Moon @ 2003-05-06 10:18 UTC (permalink / raw)
To: netdev
Hi, there.
I'm recently analyzing the kernel source for IPv6 router.
I found that when the kernel has no forwarding entry of a packet,
the kernel sends an ICMPV6_DEST_UNREACH icmp message with
ICMPV6_ADDR_UNREACH code
to the source of the packet.
But According to RFC 2463, If the kerenl has no forwarding entry of a
packet,
the kernel must send an ICMPV6_DEST_UNREACH icmp message with ICMPV6_NOROUTE
code.
In my opinion, ip6_pkt_discard() should be modified as follows :
int ip6_pkt_discard(struct sk_buff *skb)
{
IP6_INC_STATS(Ip6OutNoRoutes);
/* icmpv6_send(skb, ICMPV6_DEST_UNREACH, ICMPV6_ADDR_UNREACH, 0,
skb->dev); */
icmpv6_send(skb, ICMPV6_DEST_UNREACH, ICMPV6_NOROUTE, 0, skb->dev);
kfree_skb(skb);
return 0;
}
How about you ? Am I right ?
And I found another doubtable thing,
ipv6_routing_header() sends an ICMPv6 Parameter Problem message if the
extention header's length is odd value.
Then ICMPv6 Parameter Problem Message includes the pointer that indicates
the byte offset of errorneous field in a packet.
ipv6_routing_header() calculates the byte offset from the beginning of the
extention header.
In my opinion, ipv6_routing_header() must calculates the byte offset from
the beginning of the
IPv6 packet.
Is this right ?
bye.
^ permalink raw reply [flat|nested] 4+ messages in thread* IPv6 : ICMPV6_DEST_UNREACH type with ICMPV6_NOROUTE code
2003-05-06 10:18 IPv6 : ICMPV6_DEST_UNREACH type with ICMPV6_NOROUTE code Seong Moon
@ 2003-05-09 11:34 ` Robert Olsson
2003-05-09 11:44 ` YOSHIFUJI Hideaki / 吉藤英明
2003-05-09 15:58 ` David S. Miller
0 siblings, 2 replies; 4+ messages in thread
From: Robert Olsson @ 2003-05-09 11:34 UTC (permalink / raw)
To: Seong Moon; +Cc: netdev
Seong Moon writes:
> I found that when the kernel has no forwarding entry of a packet,
> the kernel sends an ICMPV6_DEST_UNREACH icmp message with
> ICMPV6_ADDR_UNREACH code to the source of the packet.
>
> But According to RFC 2463, If the kerenl has no forwarding entry of a
> packet,
> the kernel must send an ICMPV6_DEST_UNREACH icmp message with ICMPV6_NOROUTE
> code.
> How about you ? Am I right ?
I think you are...
--- linux/net/ipv6/route.c.030508 2003-03-24 23:01:14.000000000 +0100
+++ linux/net/ipv6/route.c 2003-05-09 13:29:31.000000000 +0200
@@ -1166,7 +1166,7 @@
int ip6_pkt_discard(struct sk_buff *skb)
{
IP6_INC_STATS(Ip6OutNoRoutes);
- icmpv6_send(skb, ICMPV6_DEST_UNREACH, ICMPV6_ADDR_UNREACH, 0, skb->dev);
+ icmpv6_send(skb, ICMPV6_DEST_UNREACH, ICMPV6_NOROUTE, 0, skb->dev);
kfree_skb(skb);
return 0;
}
Cheers.
--ro
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: IPv6 : ICMPV6_DEST_UNREACH type with ICMPV6_NOROUTE code
2003-05-09 11:34 ` Robert Olsson
@ 2003-05-09 11:44 ` YOSHIFUJI Hideaki / 吉藤英明
2003-05-09 15:58 ` David S. Miller
1 sibling, 0 replies; 4+ messages in thread
From: YOSHIFUJI Hideaki / 吉藤英明 @ 2003-05-09 11:44 UTC (permalink / raw)
To: Robert.Olsson; +Cc: seong, netdev
In article <16059.37474.453731.39031@robur.slu.se> (at Fri, 9 May 2003 13:34:58 +0200), Robert Olsson <Robert.Olsson@data.slu.se> says:
> > the kernel must send an ICMPV6_DEST_UNREACH icmp message with ICMPV6_NOROUTE
> > code.
> > How about you ? Am I right ?
>
> I think you are...
>
> --- linux/net/ipv6/route.c.030508 2003-03-24 23:01:14.000000000 +0100
> +++ linux/net/ipv6/route.c 2003-05-09 13:29:31.000000000 +0200
> @@ -1166,7 +1166,7 @@
> int ip6_pkt_discard(struct sk_buff *skb)
> {
> IP6_INC_STATS(Ip6OutNoRoutes);
> - icmpv6_send(skb, ICMPV6_DEST_UNREACH, ICMPV6_ADDR_UNREACH, 0, skb->dev);
> + icmpv6_send(skb, ICMPV6_DEST_UNREACH, ICMPV6_NOROUTE, 0, skb->dev);
> kfree_skb(skb);
> return 0;
> }
Yes, code is already in the tree. Thanks.
--yoshfuji
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: IPv6 : ICMPV6_DEST_UNREACH type with ICMPV6_NOROUTE code
2003-05-09 11:34 ` Robert Olsson
2003-05-09 11:44 ` YOSHIFUJI Hideaki / 吉藤英明
@ 2003-05-09 15:58 ` David S. Miller
1 sibling, 0 replies; 4+ messages in thread
From: David S. Miller @ 2003-05-09 15:58 UTC (permalink / raw)
To: Robert.Olsson; +Cc: seong, netdev
From: Robert Olsson <Robert.Olsson@data.slu.se>
Date: Fri, 9 May 2003 13:34:58 +0200
Seong Moon writes:
> How about you ? Am I right ?
I think you are...
Yoshfuji already composed a patch which is already in
the tree.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2003-05-09 15:58 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-05-06 10:18 IPv6 : ICMPV6_DEST_UNREACH type with ICMPV6_NOROUTE code Seong Moon
2003-05-09 11:34 ` Robert Olsson
2003-05-09 11:44 ` YOSHIFUJI Hideaki / 吉藤英明
2003-05-09 15:58 ` David S. Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).