# CVE-2021-47312: netfilter: nf_tables: Fix dereference of null pointer flow

- Severity: Medium 5.5 (CVSS:3.1, scored by CISA-ADP) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.22%, higher than 13% of CVEs (2026-12-01)
- Published: 2024-05-21T14:35:29.963Z
- Modified: 2026-06-17T04:17:10.103Z
- Weaknesses: CWE-476
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: Linux

## Description

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

netfilter: nf_tables: Fix dereference of null pointer flow

In the case where chain->flags & NFT_CHAIN_HW_OFFLOAD is false then
nft_flow_rule_create is not called and flow is NULL. The subsequent
error handling execution via label err_destroy_flow_rule will lead
to a null pointer dereference on flow when calling nft_flow_rule_destroy.
Since the error path to err_destroy_flow_rule has to cater for null
and non-null flows, only call nft_flow_rule_destroy if flow is non-null
to fix this issue.

Addresses-Coverity: ("Explicity null dereference")

(As written by CVE List.)

## Affected

- Linux Linux: from 09b1f676e2e0bbff67c568672c565c6f31470157 before 70a5a1950cca02c5cd161bb3846b4d983eed97d3; from 3c5e44622011b9ea21bd425875dcccfc9a158f5f before 4ca041f919f13783b0b03894783deee00dbca19a; from 5.13.2 before 5.13.5
- linux linux_kernel: from 5.13.2 before 5.13.5

## References

- <https://git.kernel.org/stable/c/70a5a1950cca02c5cd161bb3846b4d983eed97d3> (patch)
- <https://git.kernel.org/stable/c/4ca041f919f13783b0b03894783deee00dbca19a> (patch)

## Sources

- CVE List: [CVE-2021-47312](https://www.cve.org/CVERecord?id=CVE-2021-47312), CVE Terms of Use, modified 2026-05-11
- NVD: [CVE-2021-47312](https://nvd.nist.gov/vuln/detail/CVE-2021-47312), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2021-47312 · Whole record: https://cve.day/CVE-2021-47312.json · Rebuilt by cve.day 2026-11-25T22:58:08.790Z
