CVSROOT: /cvs Module name: src Changes by: js...@cvs.openbsd.org 2020/04/22 11:05:07
Modified files: lib/libssl : tls13_client.c tls13_handshake.c tls13_handshake.h tls13_internal.h tls13_server.c Log message: Improve TLSv1.3 state machine for HelloRetryRequest handling. The state machine currently handles the HelloRetryRequest case by using WITH_HRR - in other words, we're explicitly indicating when we transition to the alternate path. The problem here is that we do not know if we're going to receive a ServerHello or a HelloRetryRequest until we process the message. This means that the ServerHello processing code has to handle both types of messages. The state machine and associated processing code becomes cleaner if we flip this around so that we assume we are going to receive a HelloRetryRequest and upon discovering that it is not, trigger WITHOUT_HRR and hand off to the ServerHello processing function. In particular, this makes the logic much more straight forward on the server side, when adding support for HRR. With feedback from tb@ ok tb@