In the Linux kernel, the following vulnerability has been resolved:
wifi: mac80211: Don't finalize CSA in IBSS mode if state is disconnected
When we are not connected to a channel, sending channel "switch" announcement doesn't make any sense.
The BSS list is empty in that case. This causes the for loop in cfg80211getbss() to be bypassed, so the function returns NULL (check line 1424 of net/wireless/scan.c), causing the WARNON() in ieee80211ibsscsabeacon() to get triggered (check line 500 of net/mac80211/ibss.c), which was consequently reported on the syzkaller dashboard.
Thus, check if we have an existing connection before generating the CSA beacon in ieee80211ibssfinish_csa().
[
{
"deprecated": false,
"target": {
"file": "net/mac80211/ibss.c",
"function": "ieee80211_ibss_finish_csa"
},
"signature_version": "v1",
"id": "CVE-2022-49942-082ee2fe",
"digest": {
"function_hash": "333390993942637731059164483754532729962",
"length": 585.0
},
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@d9eb37db6a28b59a95a3461450ee209654c5f95b"
},
{
"deprecated": false,
"target": {
"file": "net/mac80211/ibss.c",
"function": "ieee80211_ibss_finish_csa"
},
"signature_version": "v1",
"id": "CVE-2022-49942-346b4acc",
"digest": {
"function_hash": "322835013263526808083798774421158996549",
"length": 510.0
},
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@552ba102a6898630a7d16887f29e606d6fabe508"
},
{
"deprecated": false,
"target": {
"file": "net/mac80211/ibss.c"
},
"signature_version": "v1",
"id": "CVE-2022-49942-3820a8d6",
"digest": {
"threshold": 0.9,
"line_hashes": [
"148124815643105973899150773098991924612",
"83815940903208007239956380877340860334",
"137966977051083686178835396384211549698"
]
},
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@cdb9a8da9b84800eb15506cd9363cf0cf059e677"
},
{
"deprecated": false,
"target": {
"file": "net/mac80211/ibss.c"
},
"signature_version": "v1",
"id": "CVE-2022-49942-55aa1b6f",
"digest": {
"threshold": 0.9,
"line_hashes": [
"148124815643105973899150773098991924612",
"83815940903208007239956380877340860334",
"137966977051083686178835396384211549698"
]
},
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@1691a48aef0a82d1754b9853dae7e3f5cacdf70b"
},
{
"deprecated": false,
"target": {
"file": "net/mac80211/ibss.c"
},
"signature_version": "v1",
"id": "CVE-2022-49942-6a103a39",
"digest": {
"threshold": 0.9,
"line_hashes": [
"277672531121244069004726578718116086160",
"311465359927968998608608759534639969579",
"137966977051083686178835396384211549698"
]
},
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@552ba102a6898630a7d16887f29e606d6fabe508"
},
{
"deprecated": false,
"target": {
"file": "net/mac80211/ibss.c",
"function": "ieee80211_ibss_finish_csa"
},
"signature_version": "v1",
"id": "CVE-2022-49942-7403b110",
"digest": {
"function_hash": "333390993942637731059164483754532729962",
"length": 585.0
},
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@66689c5c02acd4d76c28498fe220998610aec61e"
},
{
"deprecated": false,
"target": {
"file": "net/mac80211/ibss.c"
},
"signature_version": "v1",
"id": "CVE-2022-49942-947d39af",
"digest": {
"threshold": 0.9,
"line_hashes": [
"277672531121244069004726578718116086160",
"311465359927968998608608759534639969579",
"137966977051083686178835396384211549698"
]
},
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@dd649b49219a0388cc10fc40e4c2ea681566a780"
},
{
"deprecated": false,
"target": {
"file": "net/mac80211/ibss.c",
"function": "ieee80211_ibss_finish_csa"
},
"signature_version": "v1",
"id": "CVE-2022-49942-98730519",
"digest": {
"function_hash": "333390993942637731059164483754532729962",
"length": 585.0
},
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@1691a48aef0a82d1754b9853dae7e3f5cacdf70b"
},
{
"deprecated": false,
"target": {
"file": "net/mac80211/ibss.c"
},
"signature_version": "v1",
"id": "CVE-2022-49942-989cdb74",
"digest": {
"threshold": 0.9,
"line_hashes": [
"148124815643105973899150773098991924612",
"83815940903208007239956380877340860334",
"137966977051083686178835396384211549698"
]
},
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@d9eb37db6a28b59a95a3461450ee209654c5f95b"
},
{
"deprecated": false,
"target": {
"file": "net/mac80211/ibss.c",
"function": "ieee80211_ibss_finish_csa"
},
"signature_version": "v1",
"id": "CVE-2022-49942-9cc7b774",
"digest": {
"function_hash": "333390993942637731059164483754532729962",
"length": 585.0
},
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@cdb9a8da9b84800eb15506cd9363cf0cf059e677"
},
{
"deprecated": false,
"target": {
"file": "net/mac80211/ibss.c",
"function": "ieee80211_ibss_finish_csa"
},
"signature_version": "v1",
"id": "CVE-2022-49942-b3017f6a",
"digest": {
"function_hash": "322835013263526808083798774421158996549",
"length": 510.0
},
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@864e280cb3a9a0f5212b16ef5057c4e692f7039d"
},
{
"deprecated": false,
"target": {
"file": "net/mac80211/ibss.c",
"function": "ieee80211_ibss_finish_csa"
},
"signature_version": "v1",
"id": "CVE-2022-49942-b6bd93e0",
"digest": {
"function_hash": "164971647115079620462426185364026658353",
"length": 530.0
},
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@15bc8966b6d3a5b9bfe4c9facfa02f2b69b1e5f0"
},
{
"deprecated": false,
"target": {
"file": "net/mac80211/ibss.c",
"function": "ieee80211_ibss_finish_csa"
},
"signature_version": "v1",
"id": "CVE-2022-49942-b8b0caef",
"digest": {
"function_hash": "322835013263526808083798774421158996549",
"length": 510.0
},
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@dd649b49219a0388cc10fc40e4c2ea681566a780"
},
{
"deprecated": false,
"target": {
"file": "net/mac80211/ibss.c"
},
"signature_version": "v1",
"id": "CVE-2022-49942-c077895f",
"digest": {
"threshold": 0.9,
"line_hashes": [
"148124815643105973899150773098991924612",
"83815940903208007239956380877340860334",
"137966977051083686178835396384211549698"
]
},
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@66689c5c02acd4d76c28498fe220998610aec61e"
},
{
"deprecated": false,
"target": {
"file": "net/mac80211/ibss.c"
},
"signature_version": "v1",
"id": "CVE-2022-49942-ca45ce2d",
"digest": {
"threshold": 0.9,
"line_hashes": [
"277672531121244069004726578718116086160",
"311465359927968998608608759534639969579",
"137966977051083686178835396384211549698"
]
},
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@864e280cb3a9a0f5212b16ef5057c4e692f7039d"
},
{
"deprecated": false,
"target": {
"file": "net/mac80211/ibss.c"
},
"signature_version": "v1",
"id": "CVE-2022-49942-f835931d",
"digest": {
"threshold": 0.9,
"line_hashes": [
"277672531121244069004726578718116086160",
"311465359927968998608608759534639969579",
"137966977051083686178835396384211549698"
]
},
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@15bc8966b6d3a5b9bfe4c9facfa02f2b69b1e5f0"
}
]