Module Name:    src
Committed By:   maxv
Date:           Tue Apr 24 07:22:33 UTC 2018

Modified Files:
        src/sbin/ping6: ping6.c
        src/sys/netinet: icmp6.h

Log Message:
Add code 3 of paramprob, part of RFC7112: "IPv6 First Fragment has
incomplete IPv6 Header Chain". Handle this code in ping6.


To generate a diff of this commit:
cvs rdiff -u -r1.102 -r1.103 src/sbin/ping6/ping6.c
cvs rdiff -u -r1.50 -r1.51 src/sys/netinet/icmp6.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sbin/ping6/ping6.c
diff -u src/sbin/ping6/ping6.c:1.102 src/sbin/ping6/ping6.c:1.103
--- src/sbin/ping6/ping6.c:1.102	Tue Apr 24 07:12:04 2018
+++ src/sbin/ping6/ping6.c	Tue Apr 24 07:22:32 2018
@@ -1,4 +1,4 @@
-/*	$NetBSD: ping6.c,v 1.102 2018/04/24 07:12:04 maxv Exp $	*/
+/*	$NetBSD: ping6.c,v 1.103 2018/04/24 07:22:32 maxv Exp $	*/
 /*	$KAME: ping6.c,v 1.164 2002/11/16 14:05:37 itojun Exp $	*/
 
 /*
@@ -77,7 +77,7 @@ static char sccsid[] = "@(#)ping.c	8.1 (
 #else
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: ping6.c,v 1.102 2018/04/24 07:12:04 maxv Exp $");
+__RCSID("$NetBSD: ping6.c,v 1.103 2018/04/24 07:22:32 maxv Exp $");
 #endif
 #endif
 
@@ -2108,6 +2108,9 @@ pr_icmph(struct icmp6_hdr *icp, u_char *
 		case ICMP6_PARAMPROB_OPTION:
 			printf("Unrecognized Option ");
 			break;
+		case ICMP6_PARAMPROB_FRAGMENT:
+			printf("First Fragment Has Incomplete Chain ");
+			break;
 		default:
 			printf("Bad code(%d) ", icp->icmp6_code);
 			break;

Index: src/sys/netinet/icmp6.h
diff -u src/sys/netinet/icmp6.h:1.50 src/sys/netinet/icmp6.h:1.51
--- src/sys/netinet/icmp6.h:1.50	Tue Mar  6 10:57:00 2018
+++ src/sys/netinet/icmp6.h	Tue Apr 24 07:22:33 2018
@@ -1,4 +1,4 @@
-/*	$NetBSD: icmp6.h,v 1.50 2018/03/06 10:57:00 roy Exp $	*/
+/*	$NetBSD: icmp6.h,v 1.51 2018/04/24 07:22:33 maxv Exp $	*/
 /*	$KAME: icmp6.h,v 1.84 2003/04/23 10:26:51 itojun Exp $	*/
 
 
@@ -156,6 +156,7 @@ struct icmp6_hdr {
 #define ICMP6_PARAMPROB_HEADER 	 	0	/* erroneous header field */
 #define ICMP6_PARAMPROB_NEXTHEADER	1	/* unrecognized next header */
 #define ICMP6_PARAMPROB_OPTION		2	/* unrecognized option */
+#define ICMP6_PARAMPROB_FRAGMENT	3	/* incomplete chain in frag */
 
 #define ICMP6_INFOMSG_MASK		0x80	/* all informational messages */
 

Reply via email to