From: Nikos Mavrogiannopoulos Date: Sun, 22 May 2011 15:56:54 +0000 (+0200) Subject: Only reply with ECC Packet format extension if we have negotiated ECC. X-Git-Tag: gnutls_2_99_2~32 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c25fca6ffc04baabc9df3ef2bc09c859bb905f8b;p=thirdparty%2Fgnutls.git Only reply with ECC Packet format extension if we have negotiated ECC. --- diff --git a/lib/ext/ecc.c b/lib/ext/ecc.c index 7f744cacc1..e1eef100a7 100644 --- a/lib/ext/ecc.c +++ b/lib/ext/ecc.c @@ -242,6 +242,9 @@ _gnutls_supported_ecc_pf_send_params (gnutls_session_t session, gnutls_buffer_st { const opaque p[2] = {0x01, 0x00}; /* only support uncompressed point format */ + if (session->security_parameters.entity == GNUTLS_SERVER && !_gnutls_session_is_ecc(session)) + return 0; + /* this extension is only being sent on client and server side */ _gnutls_buffer_append_data(extdata, p, 2); return 2;