linux/net/rxrpc
Jeffrey Altman 1a2391c30c rxrpc: Fix detection of out of order acks
The rxrpc packet serial number cannot be safely used to compute out of
order ack packets for several reasons:

 1. The allocation of serial numbers cannot be assumed to imply the order
    by which acks are populated and transmitted.  In some rxrpc
    implementations, delayed acks and ping acks are transmitted
    asynchronously to the receipt of data packets and so may be transmitted
    out of order.  As a result, they can race with idle acks.

 2. Serial numbers are allocated by the rxrpc connection and not the call
    and as such may wrap independently if multiple channels are in use.

In any case, what matters is whether the ack packet provides new
information relating to the bounds of the window (the firstPacket and
previousPacket in the ACK data).

Fix this by discarding packets that appear to wind back the window bounds
rather than on serial number procession.

Fixes: 298bc15b20 ("rxrpc: Only take the rwind and mtu values from latest ACK")
Signed-off-by: Jeffrey Altman <jaltman@auristor.com>
Signed-off-by: David Howells <dhowells@redhat.com>
Tested-by: Marc Dionne <marc.dionne@auristor.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2019-04-12 16:57:23 -07:00
..
af_rxrpc.c rxrpc: Make rxrpc_kernel_check_life() indicate if call completed 2019-04-12 16:57:23 -07:00
ar-internal.h rxrpc: Fix detection of out of order acks 2019-04-12 16:57:23 -07:00
call_accept.c
call_event.c
call_object.c
conn_client.c
conn_event.c rxrpc: Trace received connection aborts 2019-04-12 16:57:23 -07:00
conn_object.c
conn_service.c
input.c rxrpc: Fix detection of out of order acks 2019-04-12 16:57:23 -07:00
insecure.c
Kconfig
key.c
local_event.c
local_object.c
Makefile
misc.c
net_ns.c
output.c rxrpc: avoid clang -Wuninitialized warning 2019-03-23 21:48:30 -04:00
peer_event.c rxrpc: Clear socket error 2019-04-12 16:57:23 -07:00
peer_object.c
proc.c
protocol.h
recvmsg.c
rxkad.c
security.c
sendmsg.c rxrpc: Allow errors to be returned from rxrpc_queue_packet() 2019-04-12 16:57:23 -07:00
skbuff.c
sysctl.c
utils.c