Skip to content
This repository has been archived by the owner on Sep 24, 2020. It is now read-only.

Commit

Permalink
net/tls: Fix connection stall on partial tls record
Browse files Browse the repository at this point in the history
[ Upstream commit 080324c ]

In the case of writing a partial tls record we forgot to clear the
ctx->in_tcp_sendpages flag, causing some connections to stall.

Fixes: c212d2c ("net/tls: Don't recursively call push_record during tls_write_space callbacks")
Signed-off-by: Andre Tomt <andre@tomt.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
atomt authored and gregkh committed May 19, 2018
1 parent d12769e commit 1376a64
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions net/tls/tls_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@ int tls_push_sg(struct sock *sk,
offset -= sg->offset;
ctx->partially_sent_offset = offset;
ctx->partially_sent_record = (void *)sg;
ctx->in_tcp_sendpages = false;
return ret;
}

Expand Down

0 comments on commit 1376a64

Please sign in to comment.