In the Linux kernel, the following vulnerability has been resolved:
scsi: mpt3sas: Fix NULL pointer access in mpt3sastransportport_add()
Port is allocated by sasportallocnum() and rphy is allocated by either sasenddevicealloc() or sasexpanderalloc(), all of which may return NULL. So we need to check the rphy to avoid possible NULL pointer access.
If sasrphyadd() returned with failure, rphy is set to NULL. We would access the rphy in the following lines which would also result NULL pointer access.
[
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@090305c36185c0547e4441d4c08f1cf096b32134",
"id": "CVE-2023-53124-093778e7",
"deprecated": false,
"target": {
"file": "drivers/scsi/mpt3sas/mpt3sas_transport.c"
},
"signature_version": "v1",
"digest": {
"threshold": 0.9,
"line_hashes": [
"337297780369334493260062044499038993093",
"20311077698172492265512595762615930318",
"2344233000957511848454014907158198259",
"277689627574167050828953820928066321734",
"68585463338978020519453295268609136515",
"71500183205207857890502920281225010479",
"150026537463383860535925913818947429593",
"168300742267497398135041268128123049986",
"128043957590233879239374529980884955494",
"215100891580232224581159907989064104247",
"17851947458640783142451523315724318876",
"51860522306803518772706832562390060893",
"121732007992765257700057394371597427477",
"105019575631505759254402837965599707471",
"21931923994868150860153064112151291753"
]
},
"signature_type": "Line"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@a26c775ccc4cfe46f9b718b51bd24313053c7e0b",
"id": "CVE-2023-53124-4401c78d",
"deprecated": false,
"target": {
"file": "drivers/scsi/mpt3sas/mpt3sas_transport.c"
},
"signature_version": "v1",
"digest": {
"threshold": 0.9,
"line_hashes": [
"337297780369334493260062044499038993093",
"20311077698172492265512595762615930318",
"2344233000957511848454014907158198259",
"277689627574167050828953820928066321734",
"313396647691398522531128672123892460199",
"278612940364020322845138268985017325996",
"189847410296649636725043354645586369057",
"168300742267497398135041268128123049986",
"128043957590233879239374529980884955494",
"215100891580232224581159907989064104247",
"17851947458640783142451523315724318876",
"35052834343850874241276023067510390690",
"212158331814104849891890375661658698717",
"105019575631505759254402837965599707471",
"21931923994868150860153064112151291753"
]
},
"signature_type": "Line"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@d3c57724f1569311e4b81e98fad0931028b9bdcd",
"id": "CVE-2023-53124-752c4bc3",
"deprecated": false,
"target": {
"file": "drivers/scsi/mpt3sas/mpt3sas_transport.c"
},
"signature_version": "v1",
"digest": {
"threshold": 0.9,
"line_hashes": [
"337297780369334493260062044499038993093",
"20311077698172492265512595762615930318",
"2344233000957511848454014907158198259",
"277689627574167050828953820928066321734",
"313396647691398522531128672123892460199",
"278612940364020322845138268985017325996",
"189847410296649636725043354645586369057",
"168300742267497398135041268128123049986",
"128043957590233879239374529980884955494",
"215100891580232224581159907989064104247",
"17851947458640783142451523315724318876",
"35052834343850874241276023067510390690",
"212158331814104849891890375661658698717",
"105019575631505759254402837965599707471",
"21931923994868150860153064112151291753"
]
},
"signature_type": "Line"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@b5e5bbb3fa5f8412e96c5eda7f4a4af6241d6bd3",
"id": "CVE-2023-53124-8164b0d6",
"deprecated": false,
"target": {
"function": "mpt3sas_transport_port_add",
"file": "drivers/scsi/mpt3sas/mpt3sas_transport.c"
},
"signature_version": "v1",
"digest": {
"length": 4449.0,
"function_hash": "1495020510506424677269435843157603197"
},
"signature_type": "Function"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@b5e5bbb3fa5f8412e96c5eda7f4a4af6241d6bd3",
"id": "CVE-2023-53124-957140ec",
"deprecated": false,
"target": {
"file": "drivers/scsi/mpt3sas/mpt3sas_transport.c"
},
"signature_version": "v1",
"digest": {
"threshold": 0.9,
"line_hashes": [
"337297780369334493260062044499038993093",
"20311077698172492265512595762615930318",
"2344233000957511848454014907158198259",
"277689627574167050828953820928066321734",
"313396647691398522531128672123892460199",
"278612940364020322845138268985017325996",
"189847410296649636725043354645586369057",
"168300742267497398135041268128123049986",
"128043957590233879239374529980884955494",
"215100891580232224581159907989064104247",
"17851947458640783142451523315724318876",
"35052834343850874241276023067510390690",
"212158331814104849891890375661658698717",
"105019575631505759254402837965599707471",
"21931923994868150860153064112151291753"
]
},
"signature_type": "Line"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@d3c57724f1569311e4b81e98fad0931028b9bdcd",
"id": "CVE-2023-53124-9b9524c6",
"deprecated": false,
"target": {
"function": "mpt3sas_transport_port_add",
"file": "drivers/scsi/mpt3sas/mpt3sas_transport.c"
},
"signature_version": "v1",
"digest": {
"length": 4449.0,
"function_hash": "1495020510506424677269435843157603197"
},
"signature_type": "Function"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@6f0c2f70d9929208d8427ec72c3ed91e2251e289",
"id": "CVE-2023-53124-a7ce8b39",
"deprecated": false,
"target": {
"file": "drivers/scsi/mpt3sas/mpt3sas_transport.c"
},
"signature_version": "v1",
"digest": {
"threshold": 0.9,
"line_hashes": [
"337297780369334493260062044499038993093",
"20311077698172492265512595762615930318",
"2344233000957511848454014907158198259",
"277689627574167050828953820928066321734",
"68585463338978020519453295268609136515",
"71500183205207857890502920281225010479",
"150026537463383860535925913818947429593",
"168300742267497398135041268128123049986",
"128043957590233879239374529980884955494",
"215100891580232224581159907989064104247",
"17851947458640783142451523315724318876",
"51860522306803518772706832562390060893",
"121732007992765257700057394371597427477",
"105019575631505759254402837965599707471",
"21931923994868150860153064112151291753"
]
},
"signature_type": "Line"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@9937f784a608944107dcc2ba9a9c3333f8330b9e",
"id": "CVE-2023-53124-b4c1ccda",
"deprecated": false,
"target": {
"file": "drivers/scsi/mpt3sas/mpt3sas_transport.c"
},
"signature_version": "v1",
"digest": {
"threshold": 0.9,
"line_hashes": [
"337297780369334493260062044499038993093",
"20311077698172492265512595762615930318",
"2344233000957511848454014907158198259",
"277689627574167050828953820928066321734",
"313396647691398522531128672123892460199",
"278612940364020322845138268985017325996",
"189847410296649636725043354645586369057",
"168300742267497398135041268128123049986",
"128043957590233879239374529980884955494",
"215100891580232224581159907989064104247",
"17851947458640783142451523315724318876",
"35052834343850874241276023067510390690",
"212158331814104849891890375661658698717",
"105019575631505759254402837965599707471",
"21931923994868150860153064112151291753"
]
},
"signature_type": "Line"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@a26c775ccc4cfe46f9b718b51bd24313053c7e0b",
"id": "CVE-2023-53124-c52f4437",
"deprecated": false,
"target": {
"function": "mpt3sas_transport_port_add",
"file": "drivers/scsi/mpt3sas/mpt3sas_transport.c"
},
"signature_version": "v1",
"digest": {
"length": 4449.0,
"function_hash": "1495020510506424677269435843157603197"
},
"signature_type": "Function"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@6f0c2f70d9929208d8427ec72c3ed91e2251e289",
"id": "CVE-2023-53124-ca2f3fd7",
"deprecated": false,
"target": {
"function": "mpt3sas_transport_port_add",
"file": "drivers/scsi/mpt3sas/mpt3sas_transport.c"
},
"signature_version": "v1",
"digest": {
"length": 3606.0,
"function_hash": "115432600146256820576564745923500480802"
},
"signature_type": "Function"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@9937f784a608944107dcc2ba9a9c3333f8330b9e",
"id": "CVE-2023-53124-cbdb71ed",
"deprecated": false,
"target": {
"function": "mpt3sas_transport_port_add",
"file": "drivers/scsi/mpt3sas/mpt3sas_transport.c"
},
"signature_version": "v1",
"digest": {
"length": 4449.0,
"function_hash": "1495020510506424677269435843157603197"
},
"signature_type": "Function"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@090305c36185c0547e4441d4c08f1cf096b32134",
"id": "CVE-2023-53124-f35b1e51",
"deprecated": false,
"target": {
"function": "mpt3sas_transport_port_add",
"file": "drivers/scsi/mpt3sas/mpt3sas_transport.c"
},
"signature_version": "v1",
"digest": {
"length": 3674.0,
"function_hash": "27547906287942279626304841311586633712"
},
"signature_type": "Function"
}
]