diff options
author | Daiki Ueno <dueno@redhat.com> | 2019-01-20 09:18:21 +0100 |
---|---|---|
committer | Daiki Ueno <dueno@redhat.com> | 2019-02-14 13:23:09 +0100 |
commit | ab953f5913b78479a83d72c660c23ab3d7a2c1b9 (patch) | |
tree | f7087ec5bfe855caa18dda2f27ba682f387e3659 /lib/hello_ext.c | |
parent | d9371ea986617da6960403c26326b0a9e8aeea68 (diff) | |
download | gnutls-ab953f5913b78479a83d72c660c23ab3d7a2c1b9.tar.gz |
ext/max_record: server shouldn't send it with record_size_limit
Otherwise, the connection will be disconnected by the client, as
suggested in RFC: A client MUST treat receipt of both
"max_fragment_length" and "record_size_limit" as a fatal error, and it
SHOULD generate an "illegal_parameter" alert.
Signed-off-by: Daiki Ueno <dueno@redhat.com>
Diffstat (limited to 'lib/hello_ext.c')
-rw-r--r-- | lib/hello_ext.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/hello_ext.c b/lib/hello_ext.c index 5692a14d2d..2d7cd806f6 100644 --- a/lib/hello_ext.c +++ b/lib/hello_ext.c @@ -64,7 +64,6 @@ unset_ext_data(gnutls_session_t session, const struct hello_ext_entry_st *, unsi static void unset_resumed_ext_data(gnutls_session_t session, const struct hello_ext_entry_st *, unsigned idx); static hello_ext_entry_st const *extfunc[MAX_EXT_TYPES+1] = { - [GNUTLS_EXTENSION_MAX_RECORD_SIZE] = &ext_mod_max_record_size, [GNUTLS_EXTENSION_EXT_MASTER_SECRET] = &ext_mod_ext_master_secret, [GNUTLS_EXTENSION_SUPPORTED_VERSIONS] = &ext_mod_supported_versions, [GNUTLS_EXTENSION_POST_HANDSHAKE] = &ext_mod_post_handshake, @@ -95,9 +94,10 @@ static hello_ext_entry_st const *extfunc[MAX_EXT_TYPES+1] = { #ifdef ENABLE_ALPN [GNUTLS_EXTENSION_ALPN] = &ext_mod_alpn, #endif + [GNUTLS_EXTENSION_RECORD_SIZE_LIMIT] = &ext_mod_record_size_limit, + [GNUTLS_EXTENSION_MAX_RECORD_SIZE] = &ext_mod_max_record_size, [GNUTLS_EXTENSION_PSK_KE_MODES] = &ext_mod_psk_ke_modes, [GNUTLS_EXTENSION_PRE_SHARED_KEY] = &ext_mod_pre_shared_key, - [GNUTLS_EXTENSION_RECORD_SIZE_LIMIT] = &ext_mod_record_size_limit, /* This must be the last extension registered. */ [GNUTLS_EXTENSION_DUMBFW] = &ext_mod_dumbfw, |