From c1b46d0242dc88da143842c16b99397c7add6dde Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Manuel=20P=C3=A9gouri=C3=A9-Gonnard?= Date: Wed, 16 Sep 2015 11:18:32 +0200 Subject: [PATCH] Fix bug in server parsing point formats extension This bug becomes noticeable when the extension following the "supported point formats" extension has a number starting with 0x01, which is the case of the EC J-PAKE extension, which explains what I noticed the bug now. This will be immediately backported to the stable branches, see the corresponding commits for impact analysis. --- library/ssl_srv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/ssl_srv.c b/library/ssl_srv.c index 67dad5fff..aab25e22e 100644 --- a/library/ssl_srv.c +++ b/library/ssl_srv.c @@ -299,7 +299,7 @@ static int ssl_parse_supported_point_formats( mbedtls_ssl_context *ssl, return( MBEDTLS_ERR_SSL_BAD_HS_CLIENT_HELLO ); } - p = buf + 2; + p = buf + 1; while( list_size > 0 ) { if( p[0] == MBEDTLS_ECP_PF_UNCOMPRESSED ||