summaryrefslogtreecommitdiffstats
path: root/apps/s_client.c
diff options
context:
space:
mode:
authorScott Deboy <sdeboy@secondstryke.com>2013-09-12 12:03:40 -0700
committerScott Deboy <sdeboy@secondstryke.com>2014-02-08 16:17:24 -0800
commitfc213217e8db600093bb7976a11e738c8b4bb948 (patch)
tree43f435fb75a0e7b583765aa44d63933e566472ee /apps/s_client.c
parent7198c5af1fe3c9d2b38fb2c3654ab83488fcf457 (diff)
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. (cherry picked from commit ac20719d994729970eb3b775c7bffa81f0e9f960) Conflicts: ssl/t1_lib.c
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 e06c9486e0..b9feec73a5 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,
@@ -2458,7 +2458,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)
{
@@ -2490,7 +2490,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)
{