Unregister Virtual Clocks in ptp Package

Kernel Updated 02 Oct 2025

Summary

24/04/2022
N/A
No i
Unrated
Not published

GSD-2022-1001236: ptp: unregister virtual clocks when unregistering physical clock. Affects Kernel versions >= 73f37068d540eba5f93ba3a0019bf479d35ebd76, < c49eafe6249f844c26f9866886cc6719d81762df. 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 Mobile apps built by Devnack Design, build and launch iOS and Android apps with a senior product team. From idea to store release Start a project

Background

The ptp package is a part of the Linux Kernel ecosystem. It provides functionality for Precision Time Protocol (PTP) synchronization, which is crucial for accurate timekeeping in distributed systems. PTP allows devices to synchronize their clocks with high precision, enabling applications that require precise timing. The ptp package includes both physical and virtual clocks, with virtual clocks being dependent on physical clocks. This vulnerability pertains to the unregistering process of physical clocks and the failure to unregister associated virtual clocks.

Vulnerability Detail

The vulnerability arises when physical clocks in the ptp package are unregistered without unregistering the corresponding virtual clocks. This oversight can lead to resource leaks and potential security issues. Attackers may exploit these unregistered virtual clocks to manipulate time synchronization, disrupt system operations, or launch timing-based attacks. The vulnerability was introduced in version v5.14 of the Linux Kernel and was fixed in version v5.17.2.

How To Fix

No fixed version is published for this vulnerability.

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

Workaround

As a temporary workaround, users can manually unregister virtual clocks associated with physical clocks before unregistering the physical clocks themselves. This can be achieved by identifying the virtual clocks linked to a physical clock and explicitly unregistering them using the appropriate system calls or APIs. Here is an example code snippet in C to illustrate the workaround:

// Identify and unregister virtual clocks
void unregisterVirtualClocks(struct physicalClock* pClock) {
  struct virtualClock* vClock;
  list_for_each_entry(vClock, &pClock->virtualClocks, list) {
    unregister_clock(vClock);
  }
}

// Unregister physical clock
void unregisterPhysicalClock(struct physicalClock* pClock) {
  unregister_clock(pClock);
  unregisterVirtualClocks(pClock);
}

Conclusion

In conclusion, the ptp package in the Linux Kernel ecosystem is vulnerable to a flaw where virtual clocks are not properly unregistered when unregistering physical clocks. This can lead to resource leaks and potential security risks. It is recommended to update the Linux Kernel to version v5.17.2 or later to mitigate this vulnerability. A temporary workaround is available by manually unregistering virtual clocks before unregistering physical clocks. For further assistance or support in vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for Kernel →

Share this vulnerability

FAQ

The ptp package is a component of the Linux Kernel ecosystem that provides functionality for Precision Time Protocol (PTP) synchronization. It enables accurate timekeeping in distributed systems by allowing devices to synchronize their clocks with high precision.

The vulnerability can result in resource leaks and potential security issues. Attackers may exploit unregistered virtual clocks to manipulate time synchronization, disrupt system operations, or launch timing-based attacks.

To fix this vulnerability, update the Linux Kernel to version v5.17.2 or later. This update includes the necessary commit to address the issue.

Yes, a temporary workaround involves manually unregistering virtual clocks associated with physical clocks before unregistering the physical clocks themselves. Refer to the provided code snippet for an example implementation.

The vulnerability was introduced in version v5.14 of the Linux Kernel and was fixed in version v5.17.2.

Related vulnerabilities

Recent vulnerabilities recorded for Kernel.

How To Fix

No fixed version is published for this vulnerability.

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