Re: [PATCH net v2] dccp: fix undefined behavior with 'cwnd' shift in ccid2_cwnd_restart()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Alexey Kodanev <alexey.kodanev@xxxxxxxxxx>
Date: Tue,  7 Aug 2018 20:03:57 +0300

> The shift of 'cwnd' with '(now - hc->tx_lsndtime) / hc->tx_rto' value
> can lead to undefined behavior [1].
> 
> In order to fix this use a gradual shift of the window with a 'while'
> loop, similar to what tcp_cwnd_restart() is doing.
> 
> When comparing delta and RTO there is a minor difference between TCP
> and DCCP, the last one also invokes dccp_cwnd_restart() and reduces
> 'cwnd' if delta equals RTO. That case is preserved in this change.
 ...
> Fixes: 113ced1f52e5 ("dccp ccid-2: Perform congestion-window validation")
> Signed-off-by: Alexey Kodanev <alexey.kodanev@xxxxxxxxxx>
> ---
> 
> v2: instead of checking the value with min(), use gradual shifting,
>     similar to tcp_cwnd_restart().

Applied and queued up for -stable, thanks.
--
To unsubscribe from this list: send the line "unsubscribe dccp" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Kernel]     [IETF DCCP]     [Linux Networking]     [Git]     [Security]     [Linux Assembly]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux