Use-after-free vulnerability in net/nfc package

Kernel Updated 02 Oct 2025

Summary

31/05/2021
N/A
No i
Unrated
Not published

GSD-2021-1000478: net/nfc: fix use-after-free llcp_sock_bind/connect. Affects Kernel versions >= 538a6ff11516d38a61e237d2d2dc04c30c845fbe, < 18ae4a192a4496e48a5490b52812645d2413307c. No fix is published. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Your last release was probably never penetration tested Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

The net/nfc package is a part of the Linux Kernel and is responsible for handling Near Field Communication (NFC) functionality. NFC enables communication between devices in close proximity, allowing for contactless data transfer. The package provides various protocols and APIs for NFC communication. However, a use-after-free vulnerability has been identified in the llcp_sock_bind/connect functions of the package.

Vulnerability Detail

The use-after-free vulnerability in net/nfc's llcp_sock_bind/connect functions can be exploited by an attacker to execute arbitrary code or cause a denial of service. The vulnerability occurs when a socket is closed, but references to it are still present, leading to a use of freed memory. An attacker can craft a malicious request to trigger this vulnerability and potentially gain control over the affected system. This vulnerability was introduced in Linux Kernel version v4.14.231 and is fixed in version v4.14.233.

How To Fix

No fixed version is published for this vulnerability.

To fix this vulnerability, it is recommended to update the Linux Kernel to version v4.14.233 or later. This can be done by pulling the latest updates from the official Linux Kernel repository and rebuilding the kernel. Additionally, it is advisable to regularly update the kernel to ensure the latest security patches are applied.

Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →

Workaround

If updating the kernel is not immediately feasible, a possible workaround is to disable NFC functionality or restrict access to the vulnerable llcp_sock_bind/connect functions. This can be achieved by modifying the kernel configuration or using kernel command-line parameters. However, it is important to note that workarounds may not provide complete protection and updating the kernel is still the recommended solution.

Conclusion

The use-after-free vulnerability in the net/nfc package's llcp_sock_bind/connect functions poses a significant security risk. It is crucial to update the Linux Kernel to version v4.14.233 or later to mitigate this vulnerability. Regularly updating the kernel and staying informed about security patches is essential for maintaining a secure system. For further support and assistance in vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for Kernel →

Share this vulnerability

FAQ

This vulnerability can allow an attacker to execute arbitrary code or cause a denial of service on the affected system.

You can use the Vulert Playground at Vulert Scanner to check if your system is affected by this vulnerability. Simply upload your package-lock.json file and Vulert will analyze it for any open-source vulnerabilities, including this one.

At the time of this report, there is no known public exploit for this vulnerability. However, it is advisable to patch the vulnerability as soon as possible to mitigate any potential risks.

Yes, this vulnerability can be exploited remotely if the affected system is accessible over a network and the necessary conditions are met.

The primary mitigation for this vulnerability is to update the Linux Kernel to the fixed version. Disabling NFC functionality or restricting access to the vulnerable functions can serve as temporary mitigations until the kernel update is applied.

Related vulnerabilities

Recent vulnerabilities recorded for Kernel.

How To Fix

No fixed version is published for this vulnerability.

To fix this vulnerability, it is recommended to update the Linux Kernel to version v4.14.233 or later. This can be done by pulling the latest updates from the official Linux Kernel repository and rebuilding the kernel. Additionally, it is advisable to regularly update the kernel to ensure the latest security patches are applied.

Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback

Follow Vulert in Google

Get more Vulert vulnerability and dependency-security updates in Google Search and AI results.