Commit a34dcbfa authored by Dan Carpenter's avatar Dan Carpenter Committed by David S. Miller

sctp: prevent info leak in sctp_make_heartbeat()

The "hbinfo" struct has a 4 byte hole at the end so we have to zero it
out to prevent stack information from being disclosed.

Fixes: fe59379b ("sctp: do the basic send and recv for PLPMTUD probe")
Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 996af621
...@@ -1163,7 +1163,7 @@ struct sctp_chunk *sctp_make_heartbeat(const struct sctp_association *asoc, ...@@ -1163,7 +1163,7 @@ struct sctp_chunk *sctp_make_heartbeat(const struct sctp_association *asoc,
const struct sctp_transport *transport, const struct sctp_transport *transport,
__u32 probe_size) __u32 probe_size)
{ {
struct sctp_sender_hb_info hbinfo; struct sctp_sender_hb_info hbinfo = {};
struct sctp_chunk *retval; struct sctp_chunk *retval;
retval = sctp_make_control(asoc, SCTP_CID_HEARTBEAT, 0, retval = sctp_make_control(asoc, SCTP_CID_HEARTBEAT, 0,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment