CVE-2025-21924: net: hns3: make sure ptp clock is unregister and freed if hclge_ptp_get_cycle returns an error
In the Linux kernel, the following vulnerability has been resolved:
net: hns3: make sure ptp clock is unregister and freed if hclge_ptp_get_cycle returns an error
During the initialization of ptp, hclge_ptp_get_cycle might return an error
and returned directly without unregister clock and free it. To avoid that,
call hclge_ptp_destroy_clock to unregist and free clock if
hclge_ptp_get_cycle failed.
Security readout for executives and security teams
Plain-English summary
A Linux HNS3 network-driver error path can leave a Precision Time Protocol clock registered and allocated when initialization fails. This incorrect cleanup may affect system security or stability. Exposure appears limited to systems using the relevant HNS3 hardware and PTP functionality; the supplied sources do not establish remote exploitation.
Executive priority
Treat this as a high-priority, targeted Linux kernel update rather than an internet-wide emergency. First identify HNS3-equipped hosts using PTP, then apply distribution-supported kernels containing the fix. There is no supplied evidence of active exploitation, but the 7.8 score and kernel-level impact justify prompt remediation on exposed systems.
Technical view
During HNS3 PTP initialization, hclge_ptp_get_cycle can fail after clock registration. The vulnerable path returns without calling hclge_ptp_destroy_clock, leaving the clock registered and allocated. Stable-kernel commits add the missing cleanup. CVSS 3.1 scores this 7.8 with local, low-privilege access and potentially high confidentiality, integrity, and availability impact.
Likely exposure
Prioritize Linux hosts using the HNS3 driver with PTP enabled or initialized. The bundle lists affected kernel versions including 5.14, 5.15.179, 6.1.131, 6.6.83, 6.12.19, 6.13.7, and 6.14, but its version representation is ambiguous; confirm exact status with the distribution vendor.
Exploitation context
CVE-2025-21924 is not identified as a KEV, and the supplied sources provide no evidence of active exploitation. The CVSS vector describes local exploitation requiring low privileges and no user interaction. The precise path from the cleanup flaw to the scored confidentiality, integrity, and availability impacts is not explained in the bundle.
Researcher notes
The disclosed defect is missing error-path cleanup after hclge_ptp_get_cycle fails: the registered PTP clock is not unregistered or freed. The fix invokes hclge_ptp_destroy_clock before returning. The bundle supplies multiple stable-branch commits but no proof of exploitation, trigger prevalence, CWE assignment, or detailed impact mechanism; those gaps limit exploitability assessment.
Mitigation direction
Install a vendor kernel containing the applicable upstream stable fix.
Follow distribution guidance for the running kernel branch and architecture.
Prioritize HNS3-equipped systems where PTP functionality is enabled.
If patching is delayed, consult the vendor about safely disabling unused HNS3 PTP functionality.
Validation and detection
Inventory kernel versions and identify systems using the HNS3 network driver.
Determine whether HNS3 Precision Time Protocol functionality is enabled or initialized.
Verify the installed vendor kernel includes the applicable stable-kernel fix.
Review kernel logs for HNS3 PTP initialization failures or related resource errors.
Retest HNS3 PTP initialization after updating the kernel.
Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cve · low confidence lookup
CVE-2025-21924 mapping review
Open the CVE-to-ATT&CK bridge for reviewed, inferred, or future official mappings tied to this CVE.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.
1CVSS vectors
3Timeline events
1ADP providers
8Source links
CVSS vector scores
1 official score
We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.