1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-16 10:20:30 +00:00

Don't consider a SYN/ACK with CC but no CCECHO a proper T/TCP

handshake.

Reviewed by:	Rich Stevens <rstevens@kohala.com>
This commit is contained in:
Bill Fenner 1997-09-30 16:38:09 +00:00
parent eb48dd32da
commit 026650e576
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=30005
2 changed files with 22 additions and 18 deletions

View File

@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)tcp_input.c 8.12 (Berkeley) 5/24/95
* $Id: tcp_input.c,v 1.60 1997/08/16 19:15:39 wollman Exp $
* $Id: tcp_input.c,v 1.61 1997/09/16 18:36:05 joerg Exp $
*/
#include "opt_tcpdebug.h"
@ -808,15 +808,17 @@ tcp_input(m, iphlen)
* option, check it to make sure this segment really
* matches our SYN. If not, just drop it as old
* duplicate, but send an RST if we're still playing
* by the old rules.
* by the old rules. If no CC.ECHO option, make sure
* we don't get fooled into using T/TCP.
*/
if ((to.to_flag & TOF_CCECHO) &&
tp->cc_send != to.to_ccecho) {
if (taop->tao_ccsent != 0)
goto drop;
else
goto dropwithreset;
}
if (to.to_flag & TOF_CCECHO) {
if (tp->cc_send != to.to_ccecho)
if (taop->tao_ccsent != 0)
goto drop;
else
goto dropwithreset;
} else
tp->t_flags &= ~TF_RCVD_CC;
tcpstat.tcps_connects++;
soisconnected(so);
/* Do window scaling on this connection? */

View File

@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)tcp_input.c 8.12 (Berkeley) 5/24/95
* $Id: tcp_input.c,v 1.60 1997/08/16 19:15:39 wollman Exp $
* $Id: tcp_input.c,v 1.61 1997/09/16 18:36:05 joerg Exp $
*/
#include "opt_tcpdebug.h"
@ -808,15 +808,17 @@ tcp_input(m, iphlen)
* option, check it to make sure this segment really
* matches our SYN. If not, just drop it as old
* duplicate, but send an RST if we're still playing
* by the old rules.
* by the old rules. If no CC.ECHO option, make sure
* we don't get fooled into using T/TCP.
*/
if ((to.to_flag & TOF_CCECHO) &&
tp->cc_send != to.to_ccecho) {
if (taop->tao_ccsent != 0)
goto drop;
else
goto dropwithreset;
}
if (to.to_flag & TOF_CCECHO) {
if (tp->cc_send != to.to_ccecho)
if (taop->tao_ccsent != 0)
goto drop;
else
goto dropwithreset;
} else
tp->t_flags &= ~TF_RCVD_CC;
tcpstat.tcps_connects++;
soisconnected(so);
/* Do window scaling on this connection? */