In the Linux kernel, the following vulnerability has been resolved:
ice: Fix DMA mappings leak
Fix leak, when user changes ring parameters. During reallocation of RX buffers, new DMA mappings are created for those buffers. New buffers with different RX ring count should substitute older ones, but those buffers were freed in icevsicfgrxq and reallocated again with iceallocrxbuf. kfree on rxbuf caused leak of already mapped DMA. Reallocate ZC with xdpbuf struct, when BPF program loads. Reallocate back to rxbuf, when BPF program unloads. If BPF program is loaded/unloaded and XSK pools are created, reallocate RX queues accordingly in XDPSETUPXSKPOOL handler.
Steps for reproduction: while : do for ((i=0; i<=8160; i=i+32)) do ethtool -G enp130s0f0 rx $i tx $i sleep 0.5 ethtool -g enp130s0f0 done done
[
{
"digest": {
"threshold": 0.9,
"line_hashes": [
"299879898660412228853377606971039876115",
"191847468239409823188474655308955002061",
"322212687984889030232072340234844162498",
"104022855535481856714094368362829941844",
"321222199250039701574233359644639337646",
"21353370240338061835588910602512840907",
"293133793098033472278074140413928749197",
"156921000444533334444771122003252688400"
]
},
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@07f40e9f0ff342eb3e97d5c544783b7cb641689c",
"signature_version": "v1",
"id": "CVE-2022-48690-212c2fc7",
"signature_type": "Line",
"target": {
"file": "drivers/net/ethernet/intel/ice/ice_main.c"
}
},
{
"digest": {
"threshold": 0.9,
"line_hashes": [
"310997392901611210917764710173927136662",
"237560543889424784424808888845656001028",
"287283278127434907677404583362943922911",
"301880228302799189322084012018383784452",
"242538398329613148313859433704737268495",
"91902397119080734884212949135072185583",
"92157032973307617830026234218222597361",
"99726113352955896991835767724934249640",
"132264683283074309195423513690968727950",
"6745715517125534288107294036545702186",
"307004237521442222408160695262821044973",
"183938404631199735484230076991298406540",
"117657875521664433160119542283923196666",
"125639233722408866364411379940344100220",
"86604622798666103129953143729093507894",
"200314685709042107066624406776887696520",
"93896187189992032290645253457073825254",
"83642810025568400722230226319655780276",
"306299814089082350031919153744266317557",
"92351441236589869682735386255957914617",
"69464387825575920994233662822330596350",
"217683372396309052078759293627462342521",
"278246833721324302974437653169796567252",
"35835662025779031240265438680552529427",
"304760821463619148025390228438416069462",
"146965391567381924104307715513278342727"
]
},
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@07f40e9f0ff342eb3e97d5c544783b7cb641689c",
"signature_version": "v1",
"id": "CVE-2022-48690-224fc67d",
"signature_type": "Line",
"target": {
"file": "drivers/net/ethernet/intel/ice/ice_base.c"
}
},
{
"digest": {
"threshold": 0.9,
"line_hashes": [
"335708845608081220376797380807141017790",
"314497255349157746839371288731129058208",
"234907758111596136705231270593307586113",
"43706542058854459119974653616878745321",
"157909202015166143220212066710018200773",
"181800008811001237015186696656494108716",
"329595699166494282733157448970533979033"
]
},
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@07f40e9f0ff342eb3e97d5c544783b7cb641689c",
"signature_version": "v1",
"id": "CVE-2022-48690-5ba0e71b",
"signature_type": "Line",
"target": {
"file": "drivers/net/ethernet/intel/ice/ice_xsk.h"
}
},
{
"digest": {
"function_hash": "50521586274575659649142391663414681883",
"length": 1107.0
},
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@07f40e9f0ff342eb3e97d5c544783b7cb641689c",
"signature_version": "v1",
"id": "CVE-2022-48690-6e47311f",
"signature_type": "Function",
"target": {
"function": "ice_qp_dis",
"file": "drivers/net/ethernet/intel/ice/ice_xsk.c"
}
},
{
"digest": {
"function_hash": "298291243929289048543589619574776166185",
"length": 164.0
},
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@07f40e9f0ff342eb3e97d5c544783b7cb641689c",
"signature_version": "v1",
"id": "CVE-2022-48690-70288512",
"signature_type": "Function",
"target": {
"function": "ice_alloc_rx_buf",
"file": "drivers/net/ethernet/intel/ice/ice_base.c"
}
},
{
"digest": {
"function_hash": "303109430655871662218320849622315654177",
"length": 1924.0
},
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@07f40e9f0ff342eb3e97d5c544783b7cb641689c",
"signature_version": "v1",
"id": "CVE-2022-48690-a45c7f4f",
"signature_type": "Function",
"target": {
"function": "ice_vsi_cfg_rxq",
"file": "drivers/net/ethernet/intel/ice/ice_base.c"
}
},
{
"digest": {
"function_hash": "157031160025379393036612234184600575225",
"length": 1226.0
},
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@07f40e9f0ff342eb3e97d5c544783b7cb641689c",
"signature_version": "v1",
"id": "CVE-2022-48690-db21c32d",
"signature_type": "Function",
"target": {
"function": "ice_xsk_pool_setup",
"file": "drivers/net/ethernet/intel/ice/ice_xsk.c"
}
},
{
"digest": {
"threshold": 0.9,
"line_hashes": [
"321778474123081289813086188400297580568",
"105655161357382556367819040101084329327",
"12785998396225418065805977624266584486",
"92538106360559271469156460464027394192",
"100072451128280967791151525154495119132",
"89418849415014723180111314136363228265",
"198185014390397167303971762642851493252",
"220911136648111035208947735193108731006",
"14413158207028788242088773743452120609",
"150879362069769058696492215849032728687",
"138060063456638126557832665533886476708",
"106241647793555334247365685742356982350",
"35830760762051666804141984470661821499",
"334747339532809646998147353308391873950",
"148071435732000617617479589404875885473",
"74626832925607957850166401647727517836"
]
},
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@07f40e9f0ff342eb3e97d5c544783b7cb641689c",
"signature_version": "v1",
"id": "CVE-2022-48690-f586311b",
"signature_type": "Line",
"target": {
"file": "drivers/net/ethernet/intel/ice/ice_xsk.c"
}
},
{
"digest": {
"function_hash": "225385421548444316035475463723694237152",
"length": 1053.0
},
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@07f40e9f0ff342eb3e97d5c544783b7cb641689c",
"signature_version": "v1",
"id": "CVE-2022-48690-faef7b57",
"signature_type": "Function",
"target": {
"function": "ice_xdp_setup_prog",
"file": "drivers/net/ethernet/intel/ice/ice_main.c"
}
},
{
"digest": {
"function_hash": "177294957062802838907439879821180943674",
"length": 167.0
},
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@07f40e9f0ff342eb3e97d5c544783b7cb641689c",
"signature_version": "v1",
"id": "CVE-2022-48690-ff646d8a",
"signature_type": "Function",
"target": {
"function": "ice_alloc_rx_buf_zc",
"file": "drivers/net/ethernet/intel/ice/ice_base.c"
}
}
]