In the Linux kernel, the following vulnerability has been resolved:
ksmbd: validate session id and tree id in compound request
smb2_get_msg() in smb2getksmbdtcon() and smb2checkusersession()
will always return the first request smb2 header in a compound request.
if SMB2_TREE_CONNECT_HE is the first command in compound request, will
return 0, i.e. The tree id check is skipped.
This patch use ksmbdreqbuf_next() to get current command in compound.
[
{
"target": {
"file": "fs/ksmbd/smb2pdu.c"
},
"signature_type": "Line",
"signature_version": "v1",
"digest": {
"threshold": 0.9,
"line_hashes": [
"314114778691861352691674272884650686939",
"179009439859036761731800321911301527446",
"267162110132818310050397398542124695644",
"162870346127257452803088579265055313640",
"311276446047388058347008046600828830845",
"115445420372303393940333194945109082892",
"152673160142468479804102473929354208428",
"212351798938790602370690937317829209410",
"279237330481759816117039500920709714247",
"166774823524589010815061065065793710948",
"294927928926202382067799527596989942926",
"43875435953798234382464620393324090427",
"219312813918507647594387712390533084115",
"213704572000106640034690912336866395587",
"234221029696074978106873631474513060955",
"122483738730445111454614983940718707477",
"296708006196616508043373078362061838631",
"173366342123958216362156539005887912033",
"324227619158098997701440529815423841192",
"245475756017105683870186484593627044875"
]
},
"deprecated": false,
"id": "CVE-2023-52442-19394e17",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@017d85c94f02090a87f4a473dbe0d6ee0da72693"
},
{
"target": {
"file": "fs/smb/server/smb2pdu.c"
},
"signature_type": "Line",
"signature_version": "v1",
"digest": {
"threshold": 0.9,
"line_hashes": [
"314114778691861352691674272884650686939",
"179009439859036761731800321911301527446",
"267162110132818310050397398542124695644",
"162870346127257452803088579265055313640",
"311276446047388058347008046600828830845",
"115445420372303393940333194945109082892",
"152673160142468479804102473929354208428",
"212351798938790602370690937317829209410",
"279237330481759816117039500920709714247",
"166774823524589010815061065065793710948",
"294927928926202382067799527596989942926",
"43875435953798234382464620393324090427",
"219312813918507647594387712390533084115",
"213704572000106640034690912336866395587",
"234221029696074978106873631474513060955",
"122483738730445111454614983940718707477",
"296708006196616508043373078362061838631",
"173366342123958216362156539005887912033",
"324227619158098997701440529815423841192",
"245475756017105683870186484593627044875"
]
},
"deprecated": false,
"id": "CVE-2023-52442-3cf74a4d",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@becb5191d1d5fdfca0198a2e37457bbbf4fe266f"
},
{
"target": {
"function": "smb2_check_user_session",
"file": "fs/smb/server/smb2pdu.c"
},
"signature_type": "Function",
"signature_version": "v1",
"digest": {
"function_hash": "141438921182275685870922538477746800091",
"length": 861.0
},
"deprecated": false,
"id": "CVE-2023-52442-42ca3b6f",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@4c2b350b2e269e3fd17bbfa42de1b42775b777ac"
},
{
"target": {
"function": "smb2_get_ksmbd_tcon",
"file": "fs/smb/server/smb2pdu.c"
},
"signature_type": "Function",
"signature_version": "v1",
"digest": {
"function_hash": "203093626701630813101085817769052565625",
"length": 951.0
},
"deprecated": false,
"id": "CVE-2023-52442-54ae3d3c",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@4c2b350b2e269e3fd17bbfa42de1b42775b777ac"
},
{
"target": {
"file": "fs/smb/server/smb2pdu.c"
},
"signature_type": "Line",
"signature_version": "v1",
"digest": {
"threshold": 0.9,
"line_hashes": [
"314114778691861352691674272884650686939",
"179009439859036761731800321911301527446",
"267162110132818310050397398542124695644",
"162870346127257452803088579265055313640",
"311276446047388058347008046600828830845",
"115445420372303393940333194945109082892",
"152673160142468479804102473929354208428",
"212351798938790602370690937317829209410",
"279237330481759816117039500920709714247",
"166774823524589010815061065065793710948",
"294927928926202382067799527596989942926",
"43875435953798234382464620393324090427",
"219312813918507647594387712390533084115",
"213704572000106640034690912336866395587",
"234221029696074978106873631474513060955",
"122483738730445111454614983940718707477",
"296708006196616508043373078362061838631",
"173366342123958216362156539005887912033",
"324227619158098997701440529815423841192",
"245475756017105683870186484593627044875"
]
},
"deprecated": false,
"id": "CVE-2023-52442-5ceafd87",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@4c2b350b2e269e3fd17bbfa42de1b42775b777ac"
},
{
"target": {
"function": "smb2_check_user_session",
"file": "fs/ksmbd/smb2pdu.c"
},
"signature_type": "Function",
"signature_version": "v1",
"digest": {
"function_hash": "141438921182275685870922538477746800091",
"length": 861.0
},
"deprecated": false,
"id": "CVE-2023-52442-5f1aec8e",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@017d85c94f02090a87f4a473dbe0d6ee0da72693"
},
{
"target": {
"function": "smb2_check_user_session",
"file": "fs/smb/server/smb2pdu.c"
},
"signature_type": "Function",
"signature_version": "v1",
"digest": {
"function_hash": "141438921182275685870922538477746800091",
"length": 861.0
},
"deprecated": false,
"id": "CVE-2023-52442-622300a7",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@3df0411e132ee74a87aa13142dfd2b190275332e"
},
{
"target": {
"function": "smb2_get_ksmbd_tcon",
"file": "fs/ksmbd/smb2pdu.c"
},
"signature_type": "Function",
"signature_version": "v1",
"digest": {
"function_hash": "203093626701630813101085817769052565625",
"length": 951.0
},
"deprecated": false,
"id": "CVE-2023-52442-6d5e7f6f",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@017d85c94f02090a87f4a473dbe0d6ee0da72693"
},
{
"target": {
"function": "smb2_check_user_session",
"file": "fs/smb/server/smb2pdu.c"
},
"signature_type": "Function",
"signature_version": "v1",
"digest": {
"function_hash": "141438921182275685870922538477746800091",
"length": 861.0
},
"deprecated": false,
"id": "CVE-2023-52442-83a4b897",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@becb5191d1d5fdfca0198a2e37457bbbf4fe266f"
},
{
"target": {
"file": "fs/smb/server/smb2pdu.c"
},
"signature_type": "Line",
"signature_version": "v1",
"digest": {
"threshold": 0.9,
"line_hashes": [
"314114778691861352691674272884650686939",
"179009439859036761731800321911301527446",
"267162110132818310050397398542124695644",
"162870346127257452803088579265055313640",
"311276446047388058347008046600828830845",
"115445420372303393940333194945109082892",
"152673160142468479804102473929354208428",
"212351798938790602370690937317829209410",
"279237330481759816117039500920709714247",
"166774823524589010815061065065793710948",
"294927928926202382067799527596989942926",
"43875435953798234382464620393324090427",
"219312813918507647594387712390533084115",
"213704572000106640034690912336866395587",
"234221029696074978106873631474513060955",
"122483738730445111454614983940718707477",
"296708006196616508043373078362061838631",
"173366342123958216362156539005887912033",
"324227619158098997701440529815423841192",
"245475756017105683870186484593627044875"
]
},
"deprecated": false,
"id": "CVE-2023-52442-b820e9da",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@3df0411e132ee74a87aa13142dfd2b190275332e"
},
{
"target": {
"function": "smb2_get_ksmbd_tcon",
"file": "fs/smb/server/smb2pdu.c"
},
"signature_type": "Function",
"signature_version": "v1",
"digest": {
"function_hash": "203093626701630813101085817769052565625",
"length": 951.0
},
"deprecated": false,
"id": "CVE-2023-52442-e9e2d45b",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@3df0411e132ee74a87aa13142dfd2b190275332e"
},
{
"target": {
"function": "smb2_get_ksmbd_tcon",
"file": "fs/smb/server/smb2pdu.c"
},
"signature_type": "Function",
"signature_version": "v1",
"digest": {
"function_hash": "203093626701630813101085817769052565625",
"length": 951.0
},
"deprecated": false,
"id": "CVE-2023-52442-fe8bf065",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@becb5191d1d5fdfca0198a2e37457bbbf4fe266f"
}
]