diff options
author | Xin Long <[email protected]> | 2018-08-27 18:38:31 +0800 |
---|---|---|
committer | David S. Miller <[email protected]> | 2018-08-27 15:13:17 -0700 |
commit | bab1be79a5169ac748d8292b20c86d874022d7ba (patch) | |
tree | 6aa14f7a10ba70d73495a48e68875ec30fe013cb /tools/perf/scripts/python/call-graph-from-sql.py | |
parent | 050cdc6c9501abcd64720b8cc3e7941efee9547d (diff) |
sctp: hold transport before accessing its asoc in sctp_transport_get_next
As Marcelo noticed, in sctp_transport_get_next, it is iterating over
transports but then also accessing the association directly, without
checking any refcnts before that, which can cause an use-after-free
Read.
So fix it by holding transport before accessing the association. With
that, sctp_transport_hold calls can be removed in the later places.
Fixes: 626d16f50f39 ("sctp: export some apis or variables for sctp_diag and reuse some for proc")
Reported-by: [email protected]
Signed-off-by: Xin Long <[email protected]>
Acked-by: Neil Horman <[email protected]>
Acked-by: Marcelo Ricardo Leitner <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/call-graph-from-sql.py')
0 files changed, 0 insertions, 0 deletions