Skip to content
Fencer Vulns
high 7.8

CVE-2021-47400 json

net: hns3: do not allow call hns3_nic_net_open repeatedly

published 2024-05-21 2 y ago modified 2026-08-05 3 mo ago also EUVD-2021-34405

cvss
7.8
version 3.1, CNA
cisa kev
Not listed
not in CISA's catalog
epss
0.3%
EPSS 0.3% chance of exploitation in 30 days, percentile 17%
public exploits
0
none known

Summary

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

net: hns3: do not allow call hns3_nic_net_open repeatedly

hns3_nic_net_open() is not allowed to called repeatly, but there is no checking for this. When doing device reset and setup tc concurrently, there is a small oppotunity to call hns3_nic_net_open repeatedly, and cause kernel bug by calling napi_enable twice.

The calltrace information is like below: [ 3078.222780] ------------[ cut here ]------------ [ 3078.230255] kernel BUG at net/core/dev.c:6991! [ 3078.236224] Internal error: Oops - BUG: 0 [#1] PREEMPT SMP [ 3078.243431] Modules linked in: hns3 hclgevf hclge hnae3 vfio_iommu_type1 vfio_pci vfio_virqfd vfio pv680_mii(O) [ 3078.258880] CPU: 0 PID: 295 Comm: kworker/u8:5 Tainted: G O 5.14.0-rc4+ #1 [ 3078.269102] Hardware name: , BIOS KpxxxFPGA 1P B600 V181 08/12/2021 [ 3078.276801] Workqueue: hclge hclge_service_task [hclge] [ 3078.288774] pstate: 60400009 (nZCv daif +PAN -UAO -TCO BTYPE=--) [ 3078.296168] pc : napi_enable+0x80/0x84 tc qdisc sho[w 3d0e7v8 .e3t0h218 79] lr : hns3_nic_net_open+0x138/0x510 [hns3]

[ 3078.314771] sp : ffff8000108abb20 [ 3078.319099] x29: ffff8000108abb20 x28: 0000000000000000 x27: ffff0820a8490300 [ 3078.329121] x26: 0000000000000001 x25: ffff08209cfc6200 x24: 0000000000000000 [ 3078.339044] x23: ffff0820a8490300 x22: ffff08209cd76000 x21: ffff0820abfe3880 [ 3078.349018] x20: 0000000000000000 x19: ffff08209cd76900 x18: 0000000000000000 [ 3078.358620] x17: 0000000000000000 x16: ffffc816e1727a50 x15: 0000ffff8f4ff930 [ 3078.368895] x14: 0000000000000000 x13: 0000000000000000 x12: 0000259e9dbeb6b4 [ 3078.377987] x11: 0096a8f7e764eb40 x10: 634615ad28d3eab5 x9 : ffffc816ad8885b8 [ 3078.387091] x8 : ffff08209cfc6fb8 x7 : ffff0820ac0da058 x6 : ffff0820a8490344 [ 3078.396356] x5 : 0000000000000140 x4 : 0000000000000003 x3 : ffff08209cd76938 [ 3078.405365] x2 : 0000000000000000 x1 : 0000000000000010 x0 : ffff0820abfe38a0 [ 3078.414657] Call trace: [ 3078.418517] napi_enable+0x80/0x84 [ 3078.424626] hns3_reset_notify_up_enet+0x78/0xd0 [hns3] [ 3078.433469] hns3_reset_notify+0x64/0x80 [hns3] [ 3078.441430] hclge_notify_client+0x68/0xb0 [hclge] [ 3078.450511] hclge_reset_rebuild+0x524/0x884 [hclge] [ 3078.458879] hclge_reset_service_task+0x3c4/0x680 [hclge] [ 3078.467470] hclge_service_task+0xb0/0xb54 [hclge] [ 3078.475675] process_one_work+0x1dc/0x48c [ 3078.481888] worker_thread+0x15c/0x464 [ 3078.487104] kthread+0x160/0x170 [ 3078.492479] ret_from_fork+0x10/0x18 [ 3078.498785] Code: c8027c81 35ffffa2 d50323bf d65f03c0 (d4210000) [ 3078.506889] ---[ end trace 8ebe0340a1b0fb44 ]---

Once hns3_nic_net_open() is excute success, the flag HNS3_NIC_STATE_DOWN will be cleared. So add checking for this flag, directly return when HNS3_NIC_STATE_DOWN is no set.

Patch / fix

  • Linux Linux 5.4.151, 5.10.71, 5.14.10, 5.15
  • linux Debian 14, Debian 13, Debian 12 5.14.12-1

debian advisories DEBIAN-CVE-2021-47400

  • linux Ubuntu 20.04 LTS 5.4.0-91.102
  • linux-aws Ubuntu 20.04 LTS 5.4.0-1060.63
  • linux-gcp Ubuntu 20.04 LTS 5.4.0-1058.62
  • linux-ibm Ubuntu 20.04 LTS 5.4.0-1008.9
  • linux-kvm Ubuntu 20.04 LTS 5.4.0-1050.52
  • linux-azure Ubuntu 20.04 LTS 5.4.0-1064.67
  • linux-gkeop Ubuntu 20.04 LTS 5.4.0-1027.28
  • linux-raspi Ubuntu 20.04 LTS 5.4.0-1047.52

ubuntu advisories UBUNTU-CVE-2021-47400

Ubuntu security data © Canonical Ltd., from https://github.com/canonical/ubuntu-security-notices via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0

  • kernel RHEL 9 5.14.0-427.24.1.el9_4
  • rv RHEL 9 5.14.0-427.24.1.el9_4
  • perf RHEL 9 5.14.0-427.24.1.el9_4
  • rtla RHEL 9 5.14.0-427.24.1.el9_4
  • bpftool RHEL 9 7.3.0-427.24.1.el9_4
  • libperf RHEL 9 5.14.0-427.24.1.el9_4
  • kernel-rt RHEL 9 5.14.0-427.24.1.el9_4
  • kernel-64k RHEL 9 5.14.0-427.24.1.el9_4

red hat advisories RHSA-2024:4349RHSA-2024:4106RHSA-2024:4108

  • dtb-aarch64 openSUSE Leap 15.5 5.14.21-150500.55.68.1
  • kernel-64kb SLE Module for Basesystem 15 SP5, openSUSE Leap 15.5 5.14.21-150500.55.68.1
  • kernel-syms SLE Module for Development Tools 15 SP5, openSUSE Leap 15.5 5.14.21-150500.55.68.1
  • kernel-obs-qa openSUSE Leap 15.5 5.14.21-150500.55.68.1
  • kernel-source SLE Module for Development Tools 15 SP5, SLE Module for Basesystem 15 SP5, openSUSE Leap 15.5 5.14.21-150500.55.68.1
  • kernel-default SLE Workstation Extension 15 SP5, SLE Module for Legacy 15 SP5, SLE Module for Basesystem 15 SP5 +4 more 5.14.21-150500.55.68.1
  • kernel-kvmsmall openSUSE Leap 15.5 5.14.21-150500.55.68.1
  • kernel-zfcpdump SLE Module for Basesystem 15 SP5, openSUSE Leap 15.5 5.14.21-150500.55.68.1

suse advisories SUSE-SU-2024:2190-1SUSE-SU-2024:2189-1SUSE-SU-2024:2184-1SUSE-SU-2024:2019-1SUSE-SU-2024:2011-1SUSE-SU-2024:2008-1

  • kernel AlmaLinux 9 5.14.0-427.24.1.el9_4
  • rv AlmaLinux 9 5.14.0-427.24.1.el9_4
  • perf AlmaLinux 9 5.14.0-427.24.1.el9_4
  • rtla AlmaLinux 9 5.14.0-427.24.1.el9_4
  • bpftool AlmaLinux 9 7.3.0-427.24.1.el9_4
  • libperf AlmaLinux 9 5.14.0-427.24.1.el9_4
  • kernel-rt AlmaLinux 9 5.14.0-427.24.1.el9_4
  • kernel-64k AlmaLinux 9 5.14.0-427.24.1.el9_4

almalinux advisories ALSA-2024:4349

  • kernel Rocky Linux 9 5.14.0-427.24.1.el9_4.cloud.3.0
  • kernel Rocky Linux 9 5.14.0-427.24.1.el9_4

rocky linux advisories RXSA-2024:4349RLSA-2024:4349

Vendor advisories

What the vendors themselves say about their products: affected, fixed or not affected, and what to do.

red hat product security vex CVE-2021-47400 updated cvss 4.1

kernel: net: hns3: do not allow call hns3_nic_net_open repeatedly

  • Red Hat Enterprise Linux 9 kernel-rt, kernel-rt-kvm, kernel-rt-core, kernel-rt-modules, kernel-rt-debug-kvm, kernel-rt-debug-core, +12 more
    affected: workaround, no fix available “Red Hat has investigated whether a possible mitigation exists for this issue, and has not been able to identify a practical example. Please update the affected package as soon as possible.”
  • Red Hat CodeReady Linux Builder EUS (v.9.2) kernel-debuginfo-common-s390x 5.14.0-284.71.1.el9_2, kernel-debuginfo-common-x86_64 5.14.0-284.71.1.el9_2, kernel-debuginfo-common-aarch64 5.14.0-284.71.1.el9_2, kernel-debuginfo-common-ppc64le 5.14.0-284.71.1.el9_2
    fixed: vendor fix “Red Hat has investigated whether a possible mitigation exists for this issue, and has not been able to identify a practical example. Please update the affected package as soon as possible.” RHSA-2024:4108
  • Red Hat Enterprise Linux AppStream (v. 9) rv 5.14.0-427.24.1.el9_4, perf 5.14.0-427.24.1.el9_4, rtla 5.14.0-427.24.1.el9_4, kernel-devel-matched 5.14.0-427.24.1.el9_4, kernel-64k-devel-matched 5.14.0-427.24.1.el9_4, kernel-debug-devel-matched 5.14.0-427.24.1.el9_4, +6 more
    fixed: vendor fix “Red Hat has investigated whether a possible mitigation exists for this issue, and has not been able to identify a practical example. Please update the affected package as soon as possible.” RHSA-2024:4349
  • Red Hat Enterprise Linux AppStream EUS (v.9.2) perf 5.14.0-284.71.1.el9_2, rtla 5.14.0-284.71.1.el9_2, kernel-devel-matched 5.14.0-284.71.1.el9_2, kernel-64k-devel-matched 5.14.0-284.71.1.el9_2, kernel-debug-devel-matched 5.14.0-284.71.1.el9_2, kernel-debuginfo-common-s390x 5.14.0-284.71.1.el9_2, +5 more
    fixed: vendor fix “Red Hat has investigated whether a possible mitigation exists for this issue, and has not been able to identify a practical example. Please update the affected package as soon as possible.” RHSA-2024:4108
  • Red Hat Enterprise Linux BaseOS (v. 9) bpftool 7.3.0-427.24.1.el9_4, kernel 5.14.0-427.24.1.el9_4, kernel-64k 5.14.0-427.24.1.el9_4, kernel-core 5.14.0-427.24.1.el9_4, kernel-tools 5.14.0-427.24.1.el9_4, python3-perf 5.14.0-427.24.1.el9_4, +28 more
    fixed: vendor fix “Red Hat has investigated whether a possible mitigation exists for this issue, and has not been able to identify a practical example. Please update the affected package as soon as possible.” RHSA-2024:4349
  • Red Hat Enterprise Linux BaseOS EUS (v.9.2) bpftool 7.0.0-284.71.1.el9_2, kernel 5.14.0-284.71.1.el9_2, kernel-64k 5.14.0-284.71.1.el9_2, kernel-core 5.14.0-284.71.1.el9_2, kernel-tools 5.14.0-284.71.1.el9_2, python3-perf 5.14.0-284.71.1.el9_2, +28 more
    fixed: vendor fix “Red Hat has investigated whether a possible mitigation exists for this issue, and has not been able to identify a practical example. Please update the affected package as soon as possible.” RHSA-2024:4108
  • Red Hat Enterprise Linux CRB (v. 9) libperf 5.14.0-427.24.1.el9_4, kernel-debuginfo-common-s390x 5.14.0-427.24.1.el9_4, kernel-debuginfo-common-x86_64 5.14.0-427.24.1.el9_4, kernel-debuginfo-common-aarch64 5.14.0-427.24.1.el9_4, kernel-debuginfo-common-ppc64le 5.14.0-427.24.1.el9_4 Red Hat Enterprise Linux NFV (v. 9) kernel-rt 5.14.0-427.24.1.el9_4, kernel-rt-kvm 5.14.0-427.24.1.el9_4, kernel-rt-core 5.14.0-427.24.1.el9_4, kernel-rt-modules 5.14.0-427.24.1.el9_4, kernel-rt-debug-kvm 5.14.0-427.24.1.el9_4, kernel-rt-debug-core 5.14.0-427.24.1.el9_4, +6 more
    fixed: vendor fix “Red Hat has investigated whether a possible mitigation exists for this issue, and has not been able to identify a practical example. Please update the affected package as soon as possible.” RHSA-2024:4349
  • Red Hat Enterprise Linux Real Time EUS (v.9.2) kernel-rt 5.14.0-284.71.1.rt14.356.el9_2, kernel-rt-core 5.14.0-284.71.1.rt14.356.el9_2, kernel-rt-modules 5.14.0-284.71.1.rt14.356.el9_2, kernel-rt-debug-core 5.14.0-284.71.1.rt14.356.el9_2, kernel-rt-modules-core 5.14.0-284.71.1.rt14.356.el9_2, kernel-rt-debug-modules 5.14.0-284.71.1.rt14.356.el9_2, +4 more Red Hat Enterprise Linux Real Time for NFV EUS (v.9.2) kernel-rt 5.14.0-284.71.1.rt14.356.el9_2, kernel-rt-kvm 5.14.0-284.71.1.rt14.356.el9_2, kernel-rt-core 5.14.0-284.71.1.rt14.356.el9_2, kernel-rt-modules 5.14.0-284.71.1.rt14.356.el9_2, kernel-rt-debug-kvm 5.14.0-284.71.1.rt14.356.el9_2, kernel-rt-debug-core 5.14.0-284.71.1.rt14.356.el9_2, +6 more
    fixed: vendor fix “Red Hat has investigated whether a possible mitigation exists for this issue, and has not been able to identify a practical example. Please update the affected package as soon as possible.” RHSA-2024:4106
show 2 more
  • Red Hat Enterprise Linux RT (v. 9) kernel-rt 5.14.0-427.24.1.el9_4, kernel-rt-core 5.14.0-427.24.1.el9_4, kernel-rt-modules 5.14.0-427.24.1.el9_4, kernel-rt-debug-core 5.14.0-427.24.1.el9_4, kernel-rt-modules-core 5.14.0-427.24.1.el9_4, kernel-rt-debug-modules 5.14.0-427.24.1.el9_4, +4 more
    fixed: vendor fix “Red Hat has investigated whether a possible mitigation exists for this issue, and has not been able to identify a practical example. Please update the affected package as soon as possible.” RHSA-2024:4349
  • Red Hat Enterprise Linux 6 perf, kernel, python-perf, kernel-kdump, kernel-firmware, kernel-bootwrapper, +1 more Red Hat Enterprise Linux 7 perf, kernel, bpftool, kernel-rt, python-perf, kernel-kdump, +8 more Red Hat Enterprise Linux 8 perf, kernel, bpftool, kernel-rt, kernel-core, kernel-tools, +29 more Red Hat Enterprise Linux AppStream EUS (v.9.2) kernel-doc 5.14.0-284.71.1.el9_2
    not affected: vulnerable code not present

Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf

CISA SSVC

Exploitation
none
Automatable
no
Technical impact
partial
Assessed
2 y ago

Exploit prediction

0.26% chance of exploitation in the next 30 days, higher than 17% of all scored CVEs (FIRST EPSS, 2026-11-08).

CVSS scores

assigned by version score vector
CNA 3.1 7.8 CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
CISA ADP 3.1 4.0 CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
NVD 3.1 5.5 CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
CNA 3.1 4.0 CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L

Affected products

  • Linux Linux

Classification

Technology feeds

References

Sources

Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.