CVE-2022-50352
net: hns: fix possible memory leak in hnae_ae_register()
Check your servers for CVE-2022-50352
The Vulnpocalypse collector sends the package list of each Linux server and of its container images once a day. Vulnpocalypse shows every server where CVE-2022-50352 affects the running kernel, with the command that installs the fix. The free plan covers one server and one domain and does not need a credit card.
Description
In the Linux kernel, the following vulnerability has been resolved:
net: hns: fix possible memory leak in hnae_ae_register()
Inject fault while probing module, if device_register() fails, but the refcount of kobject is not decreased to 0, the name allocated in dev_set_name() is leaked. Fix this by calling put_device(), so that name can be freed in callback function kobject_cleanup().
unreferenced object 0xffff00c01aba2100 (size 128): comm "systemd-udevd", pid 1259, jiffies 4294903284 (age 294.152s) hex dump (first 32 bytes): 68 6e 61 65 30 00 00 00 18 21 ba 1a c0 00 ff ff hnae0....!...... 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ backtrace: [<0000000034783f26>] slab_post_alloc_hook+0xa0/0x3e0 [<00000000748188f2>] __kmem_cache_alloc_node+0x164/0x2b0 [<00000000ab0743e8>] __kmalloc_node_track_caller+0x6c/0x390 [<000000006c0ffb13>] kvasprintf+0x8c/0x118 [<00000000fa27bfe1>] kvasprintf_const+0x60/0xc8 [<0000000083e10ed7>] kobject_set_name_vargs+0x3c/0xc0 [<000000000b87affc>] dev_set_name+0x7c/0xa0 [<000000003fd8fe26>] hnae_ae_register+0xcc/0x190 [hnae] [<00000000fe97edc9>] hns_dsaf_ae_init+0x9c/0x108 [hns_dsaf] [<00000000c36ff1eb>] hns_dsaf_probe+0x548/0x748 [hns_dsaf]
Severity (CVSS)
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
- Attack vector
- local: the attacker needs local access, or a user has to open a prepared file
- Attack complexity
- low: an attack works without special conditions
- Privileges required
- low: the attacker needs an ordinary user account
- User interaction
- none: nobody has to click or open anything
- Scope
- unchanged: the damage stays inside the vulnerable component
- Impact
- confidentiality none, integrity none, availability high: what an attacker can read (confidentiality), change (integrity) or stop (availability)
Exploitation
EPSS 0.17%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 6.16% of all scored CVEs. Scores of 1 Dec 2026.
The assessment of CISA (SSVC, 14 Jan 2026):
- Exploitation
- none: CISA did not find evidence of exploitation or a public proof of concept
- Automatable
- no: each attack takes manual steps
- Technical impact
- partial: limited control or limited data
Weakness
- CWE-401 Missing Release of Memory after Effective Lifetime
Affected products
As the CNA lists them.
| Product | Versions |
|---|---|
| Linux |
affected from 6fe6611ff275522a4e4c0359e2f46cdd07780d2f, before a3c148955c22fe1d94d7a2096005679c1f22eddf affected from 6fe6611ff275522a4e4c0359e2f46cdd07780d2f, before 3b78453cca046d3b03853f0d077ad3ad130db886 affected from 6fe6611ff275522a4e4c0359e2f46cdd07780d2f, before 7ae1345f6ad715acbcdc9e1ac28153684fd498bb affected from 6fe6611ff275522a4e4c0359e2f46cdd07780d2f, before dfc0337c6dceb6449403b33ecb141f4a1458a1e9 affected from 6fe6611ff275522a4e4c0359e2f46cdd07780d2f, before 2974f3b330ef25f5d34a4948d04290c2cd7802cf affected from 6fe6611ff275522a4e4c0359e2f46cdd07780d2f, before 91f8f5342bee726ed5692583d58f69e7cc9ae60e affected from 6fe6611ff275522a4e4c0359e2f46cdd07780d2f, before 02dc0db19d944b4a90941db505ecf1aaec714be4 affected from 6fe6611ff275522a4e4c0359e2f46cdd07780d2f, before ff2f5ec5d009844ec28f171123f9e58750cef4bf
Other versions: unaffected
|
| Linux |
affected 4.4 unaffected before 4.4 unaffected from 4.9.332 up to and including 4.9.* unaffected from 4.14.298 up to and including 4.14.* unaffected from 4.19.264 up to and including 4.19.* unaffected from 5.4.221 up to and including 5.4.* unaffected from 5.10.152 up to and including 5.10.* unaffected from 5.15.76 up to and including 5.15.* unaffected from 6.0.6 up to and including 6.0.* unaffected 6.1 and later
Other versions: affected
|
Is my server affected?
This CVE is in the Linux kernel. Compare the running kernel with the fixed kernel version of your distribution, and reboot after a kernel update:
uname -r
# Debian, Ubuntu: does the changelog of the running kernel name the CVE?
zgrep -l CVE-2022-50352 /usr/share/doc/linux-image-$(uname -r)/changelog.Debian.gz
# RHEL, Rocky, Alma
rpm -q --changelog kernel | grep CVE-2022-50352
With Trivy, on the host and for a container image. When a package is affected, it prints the installed and the fixed version:
trivy rootfs --scanners vuln / | grep CVE-2022-50352
trivy image --scanners vuln IMAGE | grep CVE-2022-50352
Vulnpocalypse makes this comparison every day for the package lists of your servers and container images, including language packages (npm, PyPI, Go, Maven and others), and sends the command that installs the fix. Start free with one server and one domain or read how to install the collector.
References
Other references
- https://git.kernel.org/stable/c/a3c148955c22fe1d94d7a2096005679c1f22eddf git.kernel.org
- https://git.kernel.org/stable/c/3b78453cca046d3b03853f0d077ad3ad130db886 git.kernel.org
- https://git.kernel.org/stable/c/7ae1345f6ad715acbcdc9e1ac28153684fd498bb git.kernel.org
- https://git.kernel.org/stable/c/dfc0337c6dceb6449403b33ecb141f4a1458a1e9 git.kernel.org
- https://git.kernel.org/stable/c/2974f3b330ef25f5d34a4948d04290c2cd7802cf git.kernel.org
- https://git.kernel.org/stable/c/91f8f5342bee726ed5692583d58f69e7cc9ae60e git.kernel.org
- https://git.kernel.org/stable/c/02dc0db19d944b4a90941db505ecf1aaec714be4 git.kernel.org
- https://git.kernel.org/stable/c/ff2f5ec5d009844ec28f171123f9e58750cef4bf git.kernel.org
Source: the record CVE-2022-50352 of the CVE List (CVE Program), CVE Terms of Use; the CISA KEV catalog and the CISA ADP container; EPSS of FIRST; the CWE catalog of MITRE, CWE Terms of Use. The text of the record is shown as published. Data sources and licences.
Vulnpocalypse