{"id":"CVE-2022-49875","summary":"bpftool: Fix NULL pointer dereference when pin {PROG, MAP, LINK} without FILE","details":"In the Linux kernel, the following vulnerability has been resolved:\n\nbpftool: Fix NULL pointer dereference when pin {PROG, MAP, LINK} without FILE\n\nWhen using bpftool to pin {PROG, MAP, LINK} without FILE,\nsegmentation fault will occur. The reson is that the lack\nof FILE will cause strlen to trigger NULL pointer dereference.\nThe corresponding stacktrace is shown below:\n\ndo_pin\n  do_pin_any\n    do_pin_fd\n      mount_bpffs_for_pin\n        strlen(name) \u003c- NULL pointer dereference\n\nFix it by adding validation to the common process.","modified":"2026-04-02T08:28:01.003049Z","published":"2025-05-01T14:10:24.427Z","database_specific":{"osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/49xxx/CVE-2022-49875.json","cna_assigner":"Linux"},"references":[{"type":"WEB","url":"https://git.kernel.org/stable/c/34de8e6e0e1f66e431abf4123934a2581cb5f133"},{"type":"WEB","url":"https://git.kernel.org/stable/c/6dcdd1b68b7f9333d48d48fc77b75e7f235f6a4a"},{"type":"WEB","url":"https://git.kernel.org/stable/c/8c80b2fca4112d724dde477aed13f7b0510a2792"},{"type":"WEB","url":"https://git.kernel.org/stable/c/da5161ba94c5e9182c301dd4f09c94f715c068bd"},{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/49xxx/CVE-2022-49875.json"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-49875"},{"type":"PACKAGE","url":"https://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":"75a1e792c335b5c6d7fdb1014da47aeb64c5944f"},{"fixed":"8c80b2fca4112d724dde477aed13f7b0510a2792"},{"fixed":"6dcdd1b68b7f9333d48d48fc77b75e7f235f6a4a"},{"fixed":"da5161ba94c5e9182c301dd4f09c94f715c068bd"},{"fixed":"34de8e6e0e1f66e431abf4123934a2581cb5f133"}]}],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2022-49875.json"}}],"schema_version":"1.7.5","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H"}]}