lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:   Fri, 27 Jan 2023 12:50:52 +1100
From:   Stephen Rothwell <sfr@...b.auug.org.au>
To:     David Miller <davem@...emloft.net>,
        Networking <netdev@...r.kernel.org>
Cc:     Florian Westphal <fw@...len.de>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        Linux Next Mailing List <linux-next@...r.kernel.org>,
        Pablo Neira Ayuso <pablo@...filter.org>,
        Sriram Yagnaraman <sriram.yagnaraman@....tech>
Subject: linux-next: manual merge of the net-next tree with the net tree

Hi all,

Today's linux-next merge of the net-next tree got a conflict in:

  net/netfilter/nf_conntrack_proto_sctp.c

between commits:

  13bd9b31a969 ("Revert "netfilter: conntrack: add sctp DATA_SENT state"")
  a44b7651489f ("netfilter: conntrack: unify established states for SCTP paths")

from the net tree and commit:

  f71cb8f45d09 ("netfilter: conntrack: sctp: use nf log infrastructure for invalid packets")

from the net-next tree.

I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging.  You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.

-- 
Cheers,
Stephen Rothwell

diff --cc net/netfilter/nf_conntrack_proto_sctp.c
index 945dd40e7077,dbdfcc6cd2aa..000000000000
--- a/net/netfilter/nf_conntrack_proto_sctp.c
+++ b/net/netfilter/nf_conntrack_proto_sctp.c
@@@ -238,14 -243,16 +227,12 @@@ static int sctp_new_state(enum ip_connt
  		i = 9;
  		break;
  	case SCTP_CID_HEARTBEAT_ACK:
- 		pr_debug("SCTP_CID_HEARTBEAT_ACK");
  		i = 10;
  		break;
 -	case SCTP_CID_DATA:
 -	case SCTP_CID_SACK:
 -		i = 11;
 -		break;
  	default:
  		/* Other chunks like DATA or SACK do not change the state */
- 		pr_debug("Unknown chunk type, Will stay in %s\n",
- 			 sctp_conntrack_names[cur_state]);
+ 		pr_debug("Unknown chunk type %d, Will stay in %s\n",
+ 			 chunk_type, sctp_conntrack_names[cur_state]);
  		return cur_state;
  	}
  
@@@ -381,19 -386,21 +364,21 @@@ int nf_conntrack_sctp_packet(struct nf_
  
  		if (!sctp_new(ct, skb, sh, dataoff))
  			return -NF_ACCEPT;
 -	} else {
 -		/* Check the verification tag (Sec 8.5) */
 -		if (!test_bit(SCTP_CID_INIT, map) &&
 -		    !test_bit(SCTP_CID_SHUTDOWN_COMPLETE, map) &&
 -		    !test_bit(SCTP_CID_COOKIE_ECHO, map) &&
 -		    !test_bit(SCTP_CID_ABORT, map) &&
 -		    !test_bit(SCTP_CID_SHUTDOWN_ACK, map) &&
 -		    !test_bit(SCTP_CID_HEARTBEAT, map) &&
 -		    !test_bit(SCTP_CID_HEARTBEAT_ACK, map) &&
 -		    sh->vtag != ct->proto.sctp.vtag[dir]) {
 -			nf_ct_l4proto_log_invalid(skb, ct, state,
 -						  "verification tag check failed %x vs %x for dir %d",
 -						  sh->vtag, ct->proto.sctp.vtag[dir], dir);
 -			goto out;
 -		}
 +	}
 +
 +	/* Check the verification tag (Sec 8.5) */
 +	if (!test_bit(SCTP_CID_INIT, map) &&
 +	    !test_bit(SCTP_CID_SHUTDOWN_COMPLETE, map) &&
 +	    !test_bit(SCTP_CID_COOKIE_ECHO, map) &&
 +	    !test_bit(SCTP_CID_ABORT, map) &&
 +	    !test_bit(SCTP_CID_SHUTDOWN_ACK, map) &&
 +	    !test_bit(SCTP_CID_HEARTBEAT, map) &&
 +	    !test_bit(SCTP_CID_HEARTBEAT_ACK, map) &&
 +	    sh->vtag != ct->proto.sctp.vtag[dir]) {
- 		pr_debug("Verification tag check failed\n");
++		nf_ct_l4proto_log_invalid(skb, ct, state,
++					  "verification tag check failed %x vs %x for dir %d",
++					  sh->vtag, ct->proto.sctp.vtag[dir], dir);
 +		goto out;
  	}
  
  	old_state = new_state = SCTP_CONNTRACK_NONE;

Content of type "application/pgp-signature" skipped

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ