mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2025-04-11 03:31:36 +00:00
BUG/MEDIUM: ssl: subsequent handshakes fail after server configuration changes
On server's configuration change, if the previously used cipher is disabled, all subsequent connect attempts fail. Fix consists in freeing cached session on handshake failure.
This commit is contained in:
parent
3b5bc66554
commit
9fa8973abb
@ -747,6 +747,12 @@ int ssl_sock_handshake(struct connection *conn, unsigned int flag)
|
||||
return 1;
|
||||
|
||||
out_error:
|
||||
/* free resumed session if exists */
|
||||
if (target_srv(&conn->target) && target_srv(&conn->target)->ssl_ctx.reused_sess) {
|
||||
SSL_SESSION_free(target_srv(&conn->target)->ssl_ctx.reused_sess);
|
||||
target_srv(&conn->target)->ssl_ctx.reused_sess = NULL;
|
||||
}
|
||||
|
||||
/* Fail on all other handshake errors */
|
||||
conn->flags |= CO_FL_ERROR;
|
||||
conn->flags &= ~flag;
|
||||
|
Loading…
Reference in New Issue
Block a user