CVE-2022-50418

Source
https://nvd.nist.gov/vuln/detail/CVE-2022-50418
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2022-50418.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2022-50418
Downstream
Related
Published
2025-09-18T16:04:01Z
Modified
2025-10-21T12:59:54.285083Z
Summary
wifi: ath11k: mhi: fix potential memory leak in ath11k_mhi_register()
Details

In the Linux kernel, the following vulnerability has been resolved:

wifi: ath11k: mhi: fix potential memory leak in ath11kmhiregister()

mhialloccontroller() allocates a memory space for mhictrl. When gets some error, mhictrl should be freed with mhifreecontroller(). But when ath11kmhireadaddrfromdt() fails, the function returns without calling mhifree_controller(), which will lead to a memory leak.

We can fix it by calling mhifreecontroller() when ath11kmhireadaddrfrom_dt() fails.

References

Affected packages

Git / 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
d5c65159f2895379e11ca13f62feabe93278985d
Fixed
72ef896e80b6ec7cdc1dd42577045f8e7c9c32b3
Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
d5c65159f2895379e11ca13f62feabe93278985d
Fixed
015ced9eb63b8b19cb725a1d592d150b60494ced
Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
d5c65159f2895379e11ca13f62feabe93278985d
Fixed
43e7c3505ec70db3d3c6458824d5fa40f62e3e7b

Affected versions

v5.*

v5.10
v5.10-rc1
v5.10-rc2
v5.10-rc3
v5.10-rc4
v5.10-rc5
v5.10-rc6
v5.10-rc7
v5.11
v5.11-rc1
v5.11-rc2
v5.11-rc3
v5.11-rc4
v5.11-rc5
v5.11-rc6
v5.11-rc7
v5.12
v5.12-rc1
v5.12-rc1-dontuse
v5.12-rc2
v5.12-rc3
v5.12-rc4
v5.12-rc5
v5.12-rc6
v5.12-rc7
v5.12-rc8
v5.13
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rc3
v6.0-rc4
v6.0-rc5
v6.0-rc6
v6.0-rc7
v6.0.1
v6.0.2

Database specific

vanir_signatures

[
    {
        "signature_version": "v1",
        "id": "CVE-2022-50418-123bb8f9",
        "signature_type": "Line",
        "digest": {
            "threshold": 0.9,
            "line_hashes": [
                "260416198636941795815282340347860052292",
                "156539362931344447635343342638850515720",
                "106483589717622227755822845328824427858",
                "175163531336222655881231493829585340732",
                "114537446240299745941321211689998815950",
                "44724885755273069111091560961551511001",
                "88361908988103440842272218743061720825",
                "72230664126936719576343742248554481025",
                "178218772374484665699695462795420987954",
                "182369064836635819347226135686504982342",
                "142101384879397799136789489311233135486",
                "121790901014122956330817130265744931742",
                "324824385178394815106098721872445306339",
                "146145348766738474545750314458750740937",
                "303435242591687604861450165621517296236",
                "131220674028301129459888129149921056453",
                "245322266917541155731710808660944132308",
                "178112927759741020046311176258949352426",
                "336817579218577128887325053907738305573",
                "52679289906913760892833483748799127539",
                "164211086675451460889995268275505564825",
                "99099485498147974353465821841583187904"
            ]
        },
        "target": {
            "file": "drivers/net/wireless/ath/ath11k/mhi.c"
        },
        "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@43e7c3505ec70db3d3c6458824d5fa40f62e3e7b",
        "deprecated": false
    },
    {
        "signature_version": "v1",
        "id": "CVE-2022-50418-4b77fec7",
        "signature_type": "Line",
        "digest": {
            "threshold": 0.9,
            "line_hashes": [
                "260416198636941795815282340347860052292",
                "156539362931344447635343342638850515720",
                "106483589717622227755822845328824427858",
                "175163531336222655881231493829585340732",
                "114537446240299745941321211689998815950",
                "44724885755273069111091560961551511001",
                "88361908988103440842272218743061720825",
                "72230664126936719576343742248554481025",
                "178218772374484665699695462795420987954",
                "182369064836635819347226135686504982342",
                "142101384879397799136789489311233135486",
                "121790901014122956330817130265744931742",
                "324824385178394815106098721872445306339",
                "146145348766738474545750314458750740937",
                "303435242591687604861450165621517296236",
                "131220674028301129459888129149921056453",
                "245322266917541155731710808660944132308",
                "178112927759741020046311176258949352426",
                "336817579218577128887325053907738305573",
                "52679289906913760892833483748799127539",
                "164211086675451460889995268275505564825",
                "99099485498147974353465821841583187904"
            ]
        },
        "target": {
            "file": "drivers/net/wireless/ath/ath11k/mhi.c"
        },
        "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@015ced9eb63b8b19cb725a1d592d150b60494ced",
        "deprecated": false
    },
    {
        "signature_version": "v1",
        "id": "CVE-2022-50418-504e7bdc",
        "signature_type": "Line",
        "digest": {
            "threshold": 0.9,
            "line_hashes": [
                "260416198636941795815282340347860052292",
                "156539362931344447635343342638850515720",
                "106483589717622227755822845328824427858",
                "175163531336222655881231493829585340732",
                "114537446240299745941321211689998815950",
                "44724885755273069111091560961551511001",
                "88361908988103440842272218743061720825",
                "72230664126936719576343742248554481025",
                "178218772374484665699695462795420987954",
                "182369064836635819347226135686504982342",
                "142101384879397799136789489311233135486",
                "121790901014122956330817130265744931742",
                "324824385178394815106098721872445306339",
                "146145348766738474545750314458750740937",
                "303435242591687604861450165621517296236",
                "131220674028301129459888129149921056453",
                "245322266917541155731710808660944132308",
                "178112927759741020046311176258949352426",
                "336817579218577128887325053907738305573",
                "52679289906913760892833483748799127539",
                "164211086675451460889995268275505564825",
                "99099485498147974353465821841583187904"
            ]
        },
        "target": {
            "file": "drivers/net/wireless/ath/ath11k/mhi.c"
        },
        "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@72ef896e80b6ec7cdc1dd42577045f8e7c9c32b3",
        "deprecated": false
    },
    {
        "signature_version": "v1",
        "id": "CVE-2022-50418-57802e84",
        "signature_type": "Function",
        "digest": {
            "length": 1723.0,
            "function_hash": "153241198763421409716725161381060842584"
        },
        "target": {
            "file": "drivers/net/wireless/ath/ath11k/mhi.c",
            "function": "ath11k_mhi_register"
        },
        "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@72ef896e80b6ec7cdc1dd42577045f8e7c9c32b3",
        "deprecated": false
    },
    {
        "signature_version": "v1",
        "id": "CVE-2022-50418-acf11263",
        "signature_type": "Function",
        "digest": {
            "length": 1723.0,
            "function_hash": "153241198763421409716725161381060842584"
        },
        "target": {
            "file": "drivers/net/wireless/ath/ath11k/mhi.c",
            "function": "ath11k_mhi_register"
        },
        "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@43e7c3505ec70db3d3c6458824d5fa40f62e3e7b",
        "deprecated": false
    },
    {
        "signature_version": "v1",
        "id": "CVE-2022-50418-f53bfa66",
        "signature_type": "Function",
        "digest": {
            "length": 1723.0,
            "function_hash": "153241198763421409716725161381060842584"
        },
        "target": {
            "file": "drivers/net/wireless/ath/ath11k/mhi.c",
            "function": "ath11k_mhi_register"
        },
        "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@015ced9eb63b8b19cb725a1d592d150b60494ced",
        "deprecated": false
    }
]

Linux / Kernel

Package

Name
Kernel

Affected ranges

Type
ECOSYSTEM
Events
Introduced
5.6.0
Fixed
5.19.17
Type
ECOSYSTEM
Events
Introduced
5.20.0
Fixed
6.0.3