aboutsummaryrefslogtreecommitdiffstats
path: root/apps/s_client.c
diff options
context:
space:
mode:
authorScott Deboy <sdeboy@secondstryke.com>2013-09-12 12:03:40 -0700
committerBen Laurie <ben@links.org>2014-02-05 18:25:46 +0000
commitac20719d994729970eb3b775c7bffa81f0e9f960 (patch)
tree968d561cc089196fff817ca36bee1bdc9cbc2f78 /apps/s_client.c
parenta51f767645c117667d337f77fe1dd9c0a66d8410 (diff)
downloadopenssl-ac20719d994729970eb3b775c7bffa81f0e9f960.tar.gz
Update custom TLS extension and supplemental data 'generate' callbacks to support sending an alert.
If multiple TLS extensions are expected but not received, the TLS extension and supplemental data 'generate' callbacks are the only chance for the receive-side to trigger a specific TLS alert during the handshake. Removed logic which no-op'd TLS extension generate callbacks (as the generate callbacks need to always be called in order to trigger alerts), and updated the serverinfo-specific custom TLS extension callbacks to track which custom TLS extensions were received by the client, where no-ops for 'generate' callbacks are appropriate.
Diffstat (limited to 'apps/s_client.c')
-rw-r--r--apps/s_client.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/apps/s_client.c b/apps/s_client.c
index 1e3bc391b5..95c62a7248 100644
--- a/apps/s_client.c
+++ b/apps/s_client.c
@@ -242,11 +242,11 @@ static int suppdata_cb(SSL *s, unsigned short supp_data_type,
static int auth_suppdata_generate_cb(SSL *s, unsigned short supp_data_type,
const unsigned char **out,
- unsigned short *outlen, void *arg);
+ unsigned short *outlen, int *al, void *arg);
static int authz_tlsext_generate_cb(SSL *s, unsigned short ext_type,
const unsigned char **out, unsigned short *outlen,
- void *arg);
+ int *al, void *arg);
static int authz_tlsext_cb(SSL *s, unsigned short ext_type,
const unsigned char *in,
@@ -2456,7 +2456,7 @@ static int authz_tlsext_cb(SSL *s, unsigned short ext_type,
static int authz_tlsext_generate_cb(SSL *s, unsigned short ext_type,
const unsigned char **out, unsigned short *outlen,
- void *arg)
+ int *al, void *arg)
{
if (c_auth)
{
@@ -2488,7 +2488,7 @@ static int suppdata_cb(SSL *s, unsigned short supp_data_type,
static int auth_suppdata_generate_cb(SSL *s, unsigned short supp_data_type,
const unsigned char **out,
- unsigned short *outlen, void *arg)
+ unsigned short *outlen, int *al, void *arg)
{
if (c_auth && server_provided_client_authz && server_provided_server_authz)
{