CVE-2022-49875

bpftool: Fix NULL pointer dereference when pin {PROG, MAP, LINK} without FILE

Medium · published May 1, 2025

CVSS v3.1
5.5
EPSS
0%
Percentile
11.3
In the wild
Unconfirmed
What it is

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

bpftool: Fix NULL pointer dereference when pin {PROG, MAP, LINK} without FILE

When using bpftool to pin {PROG, MAP, LINK} without FILE,

segmentation fault will occur. The reson is that the lack

of FILE will cause strlen to trigger NULL pointer dereference.

The corresponding stacktrace is shown below:

do_pin

do_pin_any

do_pin_fd

mount_bpffs_for_pin

strlen(name) <- NULL pointer dereference

Fix it by adding validation to the common process.

The record
Technical detail
CVSS v3.1
5.5 · MEDIUM
Vector
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
CVSS v4.0
Not supplied
EPSS
0.00215 · 11.3th percentile
Published
2025-05-01T14:10Z
EPSS history
Timeline
  • 01 MAY 14:10Z
    bpftool: Fix NULL pointer dereference when pin {PROG, MAP, LINK} without FILE
    cvelistv5