{"id":"CVE-2022-50243","summary":"sctp: handle the error returned from sctp_auth_asoc_init_active_key","details":"In the Linux kernel, the following vulnerability has been resolved:\n\nsctp: handle the error returned from sctp_auth_asoc_init_active_key\n\nWhen it returns an error from sctp_auth_asoc_init_active_key(), the\nactive_key is actually not updated. The old sh_key will be freeed\nwhile it's still used as active key in asoc. Then an use-after-free\nwill be triggered when sending patckets, as found by syzbot:\n\n  sctp_auth_shkey_hold+0x22/0xa0 net/sctp/auth.c:112\n  sctp_set_owner_w net/sctp/socket.c:132 [inline]\n  sctp_sendmsg_to_asoc+0xbd5/0x1a20 net/sctp/socket.c:1863\n  sctp_sendmsg+0x1053/0x1d50 net/sctp/socket.c:2025\n  inet_sendmsg+0x99/0xe0 net/ipv4/af_inet.c:819\n  sock_sendmsg_nosec net/socket.c:714 [inline]\n  sock_sendmsg+0xcf/0x120 net/socket.c:734\n\nThis patch is to fix it by not replacing the sh_key when it returns\nerrors from sctp_auth_asoc_init_active_key() in sctp_auth_set_key().\nFor sctp_auth_set_active_key(), old active_key_id will be set back\nto asoc-\u003eactive_key_id when the same thing happens.","modified":"2026-11-17T07:00:32.139948916Z","published":"2025-09-15T14:01:52.101Z","database_specific":{"cna_assigner":"Linux","osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/50xxx/CVE-2022-50243.json"},"references":[{"type":"WEB","url":"https://git.kernel.org/stable/c/022152aaebe116a25c39818a07e175a8cd3c1e11"},{"type":"WEB","url":"https://git.kernel.org/stable/c/0f90099d18e3abdc01babf686f41f63fe04939c1"},{"type":"WEB","url":"https://git.kernel.org/stable/c/19d636b663e0e92951bba5fced929ca7fd25c552"},{"type":"WEB","url":"https://git.kernel.org/stable/c/382ff44716603a54f5fd238ddec6a2468e217612"},{"type":"WEB","url":"https://git.kernel.org/stable/c/3b0fcf5e29c0940e1169ce9c44f73edd98bdf12d"},{"type":"WEB","url":"https://git.kernel.org/stable/c/b8fa99a3a11bdd77fef6b4a97f1021eb30b5ba40"},{"type":"WEB","url":"https://git.kernel.org/stable/c/f65955340e0044f5c41ac799a01698ac7dee8a4e"},{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/50xxx/CVE-2022-50243.json"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-50243"},{"type":"PACKAGE","url":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","events":[{"introduced":"50b57223da67653c61e405d0a7592355cfe4585e"},{"fixed":"b8fa99a3a11bdd77fef6b4a97f1021eb30b5ba40"}]},{"type":"GIT","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","events":[{"introduced":"b60461696a0b0fdaf240bc365b7983698f88ded2"},{"fixed":"382ff44716603a54f5fd238ddec6a2468e217612"}]},{"type":"GIT","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","events":[{"introduced":"8eb225873246312660ccd68296959a7b213d0cdd"},{"fixed":"f65955340e0044f5c41ac799a01698ac7dee8a4e"}]},{"type":"GIT","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","events":[{"introduced":"58acd10092268831e49de279446c314727101292"},{"fixed":"19d636b663e0e92951bba5fced929ca7fd25c552"},{"fixed":"0f90099d18e3abdc01babf686f41f63fe04939c1"},{"fixed":"3b0fcf5e29c0940e1169ce9c44f73edd98bdf12d"},{"fixed":"022152aaebe116a25c39818a07e175a8cd3c1e11"}]},{"type":"GIT","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","events":[{"introduced":"c1de376423a7759bf4fa25d6a038a4c1e035c9e1"}]}],"versions":["v4.19.261","v4.19.260","v4.19.259","v4.19.258","v4.19.257","v4.19.256","v4.19.255","v4.19.254","v4.19.253","v4.19.252","v4.19.251","v4.19.250","v4.19.249","v4.19.248","v4.19.247","v4.19.246","v4.19.245","v4.19.244","v4.19.243","v4.19.242","v4.19.241","v4.19.240","v4.19.239","v4.19.238","v4.19.237","v4.19.236","v4.19.235","v4.19.234","v4.19.233","v4.19.232","v4.19.231","v4.19.230","v4.19.229","v4.19.228","v4.19.227","v4.19.226","v4.19.225","v4.19.224","v4.19.223","v4.19.222","v4.19.221","v4.19.220","v4.19.219","v4.19.218","v4.19.217","v4.19.216","v4.19.215","v4.19.214","v4.19.213","v4.19.212","v4.19.211","v4.19.210","v4.19.209","v4.19.208","v4.19.207","v4.19.206","v4.19.205","v4.19.204","v4.19.203","v4.19.202","v4.19.201","v4.19.200","v4.19.199","v5.4.219","v5.4.218","v5.4.217","v5.4.216","v5.4.215","v5.4.214","v5.4.213","v5.4.212","v5.4.211","v5.4.210","v5.4.209","v5.4.208","v5.4.207","v5.4.206","v5.4.205","v5.4.204","v5.4.203","v5.4.202","v5.4.201","v5.4.200","v5.4.199","v5.4.198","v5.4.197","v5.4.196","v5.4.195","v5.4.194","v5.4.193","v5.4.192","v5.4.191","v5.4.190","v5.4.189","v5.4.188","v5.4.187","v5.4.186","v5.4.185","v5.4.184","v5.4.183","v5.4.182","v5.4.181","v5.4.180","v5.4.179","v5.4.178","v5.4.177","v5.4.176","v5.4.175","v5.4.174","v5.4.173","v5.4.172","v5.4.171","v5.4.170","v5.4.169","v5.4.168","v5.4.167","v5.4.166","v5.4.165","v5.4.164","v5.4.163","v5.4.162","v5.4.161","v5.4.160","v5.4.159","v5.4.158","v5.4.157","v5.4.156","v5.4.155","v5.4.154","v5.4.153","v5.4.152","v5.4.151","v5.4.150","v5.4.149","v5.4.148","v5.4.147","v5.4.146","v5.4.145","v5.4.144","v5.4.143","v5.4.142","v5.4.141","v5.4.140","v5.4.139","v5.4.138","v5.4.137","v5.4.136","v5.10.149","v5.10.148","v5.10.147","v5.10.146","v5.10.145","v5.10.144","v5.10.143","v5.10.142","v5.10.141","v5.10.140","v5.10.139","v5.10.138","v5.10.137","v5.10.136","v5.10.135","v5.10.134","v5.10.133","v5.10.132","v5.10.131","v5.10.130","v5.10.129","v5.10.128","v5.10.127","v5.10.126","v5.10.125","v5.10.124","v5.10.123","v5.10.122","v5.10.121","v5.10.120","v5.10.119","v5.10.118","v5.10.117","v5.10.116","v5.10.115","v5.10.114","v5.10.113","v5.10.112","v5.10.111","v5.10.110","v5.10.109","v5.10.108","v5.10.107","v5.10.106","v5.10.105","v5.10.104","v5.10.103","v5.10.102","v5.10.101","v5.10.100","v5.10.99","v5.10.98","v5.10.97","v5.10.96","v5.10.95","v5.10.94","v5.10.93","v5.10.92","v5.10.91","v5.10.90","v5.10.89","v5.10.88","v5.10.87","v5.10.86","v5.10.85","v5.10.84","v5.10.83","v5.10.82","v5.10.81","v5.10.80","v5.10.79","v5.10.78","v5.10.77","v5.10.76","v5.10.75","v5.10.74","v5.10.73","v5.10.72","v5.10.71","v5.10.70","v5.10.69","v5.10.68","v5.10.67","v5.10.66","v5.10.65","v5.10.64","v5.10.63","v5.10.62","v5.10.61","v5.10.60","v5.10.59","v5.10.58","v5.10.57","v5.10.56","v5.10.55","v5.10.54","v5.13.19","v5.13.18","v5.13.17","v5.13.16","v5.13.15","v5.13.14","v5.13.13","v5.13.12","v5.13.11","v5.13.10","v5.13.9","v5.13.8","v5.13.7","v5.13.6"],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2022-50243.json"}},{"package":{"name":"Kernel","ecosystem":"Linux"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"4.19.199"},{"fixed":"4.19.262"}]},{"type":"ECOSYSTEM","events":[{"introduced":"5.4.136"},{"fixed":"5.4.220"}]},{"type":"ECOSYSTEM","events":[{"introduced":"5.10.54"},{"fixed":"5.10.150"}]},{"type":"ECOSYSTEM","events":[{"introduced":"5.13.6"},{"fixed":"5.14"}]},{"type":"ECOSYSTEM","events":[{"introduced":"5.14.0"},{"fixed":"5.15.75"}]},{"type":"ECOSYSTEM","events":[{"introduced":"5.16.0"},{"fixed":"5.19.17"}]},{"type":"ECOSYSTEM","events":[{"introduced":"5.20.0"},{"fixed":"6.0.3"}]}],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2022-50243.json"}}],"schema_version":"1.9.2","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H"}]}