Author: tuexen
Date: Wed Oct 18 18:56:56 2017
New Revision: 324725
URL: https://svnweb.freebsd.org/changeset/base/324725

Log:
  Fix a bug introduced in r324638.
  Thanks to Felix Weinrank for making me aware of this.
  
  MFC after:    3 days

Modified:
  head/sys/netinet/ip_fw.h
  head/sys/netinet/sctp_input.c

Modified: head/sys/netinet/ip_fw.h
==============================================================================
--- head/sys/netinet/ip_fw.h    Wed Oct 18 17:23:16 2017        (r324724)
+++ head/sys/netinet/ip_fw.h    Wed Oct 18 18:56:56 2017        (r324725)
@@ -728,6 +728,8 @@ struct _ipfw_dyn_rule {
 
 #define        ICMP_REJECT_RST         0x100   /* fake ICMP code (send a TCP 
RST) */
 #define        ICMP6_UNREACH_RST       0x100   /* fake ICMPv6 code (send a TCP 
RST) */
+#define        ICMP_REJECT_ABORT       0x101   /* fake ICMP code (send an SCTP 
ABORT */
+#define        ICMP6_UNREACH_ABORT     0x101   /* fake ICMPv6 code (send an 
SCTP ABORT) */
 
 /*
  * These are used for lookup tables.

Modified: head/sys/netinet/sctp_input.c
==============================================================================
--- head/sys/netinet/sctp_input.c       Wed Oct 18 17:23:16 2017        
(r324724)
+++ head/sys/netinet/sctp_input.c       Wed Oct 18 18:56:56 2017        
(r324725)
@@ -4536,6 +4536,7 @@ sctp_process_control(struct mbuf *m, int iphlen, int *
        if (ntohs(ch->chunk_length) < sizeof(*ch)) {
                SCTPDBG(SCTP_DEBUG_INPUT1, "Invalid header length %d\n",
                    ntohs(ch->chunk_length));
+               *offset = length;
                return (stcb);
        }
        /*
_______________________________________________
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to