[tls] Keep cipherstream window open until TLS negotiation is complete
authorMichael Brown <mcb30@ipxe.org>
Mon, 22 May 2017 12:17:23 +0000 (13:17 +0100)
committerMichael Brown <mcb30@ipxe.org>
Mon, 22 May 2017 12:17:23 +0000 (13:17 +0100)
commit2f126904555f3890a5c05868bb615d2fd62f8b0c
tree939d0ae4021f389f71a2f727d0e1513d1ed06fac
parentde37652044d51a73e8c65353e8b74a3544c54183
[tls] Keep cipherstream window open until TLS negotiation is complete

When performing a SAN boot, the plainstream window size will be zero
(since this is the mechanism used internally to indicate that no data
should be fetched via the initial request).  This zero value currently
propagates to the advertised TCP window size, which prevents the TLS
negotiation from completing.

Fix by ensuring that the cipherstream window is held open until TLS
negotiation is complete, and only then falling back to passing through
the plainstream window size.

Reported-by: John Wigley <johnwigley#ipxe@acorna.co.uk>
Tested-by: John Wigley <johnwigley#ipxe@acorna.co.uk>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
src/net/tls.c