提交 1a14b47e 编写于 作者: D Dr. Stephen Henson 提交者: Matt Caswell

Prevent use of binary curves when OPENSSL_NO_EC2M is defined

Reviewed-by: NMatt Caswell <matt@openssl.org>
上级 d253c9cd
...@@ -435,6 +435,10 @@ static int tls_curve_allowed(SSL *s, const unsigned char *curve, int op) ...@@ -435,6 +435,10 @@ static int tls_curve_allowed(SSL *s, const unsigned char *curve, int op)
sizeof(nid_list)/sizeof(nid_list[0]))) sizeof(nid_list)/sizeof(nid_list[0])))
return 0; return 0;
cinfo = &nid_list[curve[1]-1]; cinfo = &nid_list[curve[1]-1];
#ifdef OPENSSL_NO_EC2M
if (cinfo->flags & TLS_CURVE_CHAR2)
return 0;
#endif
return ssl_security(s, op, cinfo->secbits, cinfo->nid, (void *)curve); return ssl_security(s, op, cinfo->secbits, cinfo->nid, (void *)curve);
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册