提交 7facdbd6 编写于 作者: M Matt Caswell

Fix a bug in the construction of the ClienHello SRTP extension

Reviewed-by: NRich Salz <rsalz@openssl.org>
上级 7507e73d
......@@ -1302,7 +1302,7 @@ int ssl_add_clienthello_tlsext(SSL *s, WPACKET *pkt, int *al)
}
#ifndef OPENSSL_NO_SRTP
if (SSL_IS_DTLS(s) && SSL_get_srtp_profiles(s)) {
STACK_OF(SRTP_PROTECTION_PROFILE) *clnt = 0;
STACK_OF(SRTP_PROTECTION_PROFILE) *clnt = SSL_get_srtp_profiles(s);
SRTP_PROTECTION_PROFILE *prof;
int i, ct;
......@@ -1322,7 +1322,10 @@ int ssl_add_clienthello_tlsext(SSL *s, WPACKET *pkt, int *al)
return 0;
}
}
if (!WPACKET_close(pkt) || !WPACKET_close(pkt)) {
if (!WPACKET_close(pkt)
/* Add an empty use_mki value */
|| !WPACKET_put_bytes_u8(pkt, 0)
|| !WPACKET_close(pkt)) {
SSLerr(SSL_F_SSL_ADD_CLIENTHELLO_TLSEXT, ERR_R_INTERNAL_ERROR);
return 0;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册