1
0
mirror of https://github.com/irssi/irssi.git synced 2025-01-03 14:56:47 -05:00

Emit the TLS handshake finished signal before we do verification.

This patch moves the emitted "tls handshake finished" signal to before
we do validation of the given TLS certificate. This ensures that we
display certificate information before we possibly error out and
disconnects from the server.
This commit is contained in:
Alexander Færøy 2016-10-21 01:22:09 +02:00
parent 5a04430998
commit d501a54f4f
No known key found for this signature in database
GPG Key ID: E15081D5D3C3DB53

View File

@ -771,6 +771,9 @@ int irssi_ssl_handshake(GIOChannel *handle)
set_peer_cert_chain_info(tls, chan->ssl);
set_server_temporary_key_info(tls, chan->ssl);
// Emit the TLS rec.
signal_emit("tls handshake finished", 2, chan->server, tls);
ret = 1;
do {
@ -802,9 +805,6 @@ int irssi_ssl_handshake(GIOChannel *handle)
}
} while (0);
// Emit the TLS rec.
signal_emit("tls handshake finished", 2, chan->server, tls);
done:
tls_rec_free(tls);
X509_free(cert);