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>] [<thread-prev] [day] [month] [year] [list]
Date:	Wed, 12 Mar 2014 08:44:25 -0700
From:	Yuchung Cheng <ycheng@...gle.com>
To:	Eric Dumazet <eric.dumazet@...il.com>
Cc:	Yong Zhang <fell198904@...il.com>, netdev <netdev@...r.kernel.org>,
	Jerry Chu <hkchu@...gle.com>
Subject: Re: [tcp] The ssthresh reduce during 3WHS

On Wed, Mar 12, 2014 at 7:26 AM, Eric Dumazet <eric.dumazet@...il.com> wrote:
>
> On Wed, 2014-03-12 at 21:46 +0800, Yong Zhang wrote:
> > hi,
> >
> > I am trying to to apply patch 9ad7c049f0f79c418e293b1b68cf10d68f54fcdb
> > to my old version kernel, but I am not understanding the following
> > changes.
> >
> > The comments int the patch say ssthresh may reduce unnecessarily
> > druing 3WHS,  but i can not find the reduce operation of ssthresh
> > during 3WHS.
> >
> > Can you please explain when dose this may hanppen?
I can think of two cases:

1. active open: syn -> (timeout) -> tcp_retransmit_timer ->
tcp_enter_loss -> reduce ssthresh

2. passive fast open: data sent during 3whs after syn-ack -> timeout
-> tcp_enter_loss -> reduce ssthresh

It's arguable the resetting is necessary or not. but resetting
ssthresh seems better b/c it is unlikely to be the BDP, especially in
case 1.

btw, it'll be easy to test this using https://code.google.com/p/packetdrill/

> >
>
> You might CC patch author when asking such questions...
>
>
> >
> > diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c
> > index bef9f04..ea0d218 100644
> > --- a/net/ipv4/tcp_input.c
> > +++ b/net/ipv4/tcp_input.c
> > @@ -880,6 +880,11 @@ static void tcp_init_metrics(struct sock *sk)
> >
> >         tp->snd_ssthresh = dst_metric(dst, RTAX_SSTHRESH);
> >                  if (tp->snd_ssthresh > tp->snd_cwnd_clamp)
> >                          tp->snd_ssthresh = tp->snd_cwnd_clamp;
> > +       } else {
> > +                /* ssthresh may have been reduced unnecessarily during.
> > +                * 3WHS. Restore it back to its initial default.
> > +                */
> > +                tp->snd_ssthresh = TCP_INFINITE_SSTHRESH;
> >          }
> >
> >
> > Thanks,
> > Fel
> > --
> > To unsubscribe from this list: send the line "unsubscribe netdev" in
> > the body of a message to majordomo@...r.kernel.org
> > More majordomo info at  http://vger.kernel.org/majordomo-info.html
>
>
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ