CVE-2024-57849: Vulnerability in Linux Linux
In the Linux kernel, the following vulnerability has been resolved: s390/cpum_sf: Handle CPU hotplug remove during sampling CPU hotplug remove handling triggers the following function call sequence: CPUHP_AP_PERF_S390_SF_ONLINE --> s390_pmu_sf_offline_cpu() ... CPUHP_AP_PERF_ONLINE --> perf_event_exit_cpu() The s390 CPUMF sampling CPU hotplug handler invokes: s390_pmu_sf_offline_cpu() +--> cpusf_pmu_setup() +--> setup_pmc_cpu() +--> deallocate_buffers() This function de-allocates all sampling data buffers (SDBs) allocated for that CPU at event initialization. It also clears the PMU_F_RESERVED bit. The CPU is gone and can not be sampled. With the event still being active on the removed CPU, the CPU event hotplug support in kernel performance subsystem triggers the following function calls on the removed CPU: perf_event_exit_cpu() +--> perf_event_exit_cpu_context() +--> __perf_event_exit_context() +--> __perf_remove_from_context() +--> event_sched_out() +--> cpumsf_pmu_del() +--> cpumsf_pmu_stop() +--> hw_perf_event_update() to stop and remove the event. During removal of the event, the sampling device driver tries to read out the remaining samples from the sample data buffers (SDBs). But they have already been freed (and may have been re-assigned). This may lead to a use after free situation in which case the samples are most likely invalid. In the best case the memory has not been reassigned and still contains valid data. Remedy this situation and check if the CPU is still in reserved state (bit PMU_F_RESERVED set). In this case the SDBs have not been released an contain valid data. This is always the case when the event is removed (and no CPU hotplug off occured). If the PMU_F_RESERVED bit is not set, the SDB buffers are gone.
AI Analysis
Technical Summary
CVE-2024-57849 is a vulnerability identified in the Linux kernel specifically affecting the s390 architecture's CPU sampling functionality during CPU hotplug events. The issue arises when a CPU is removed (hotplugged off) while a performance monitoring event is still active on that CPU. The kernel's performance monitoring unit (PMU) sampling driver for s390 CPUs deallocates the sample data buffers (SDBs) associated with the CPU during the CPU hotplug removal process. However, the event removal sequence subsequently attempts to read from these buffers, which have already been freed. This leads to a use-after-free condition where the driver may access invalid or reallocated memory, potentially causing data corruption or kernel instability. The root cause is that the kernel does not properly check whether the CPU's PMU sampling buffers are still reserved before attempting to read from them during event removal. The fix involves verifying the PMU_F_RESERVED bit to confirm if the buffers are still valid before accessing them. If the bit is not set, the buffers have been released and should not be accessed. This vulnerability is specific to the s390 architecture's CPU sampling subsystem and involves kernel internal handling of CPU hotplug events and performance monitoring. No known exploits are reported in the wild, and the vulnerability was published on January 11, 2025. The affected versions are identified by a specific commit hash, indicating a narrow scope tied to particular kernel builds.
Potential Impact
For European organizations, the impact of CVE-2024-57849 depends largely on their use of Linux systems running on IBM s390 mainframe architectures, which are less common than x86 or ARM architectures but are used in certain enterprise and financial sectors. The vulnerability could lead to kernel crashes or instability due to use-after-free memory access during CPU hotplug events, potentially causing denial of service or system outages. This could disrupt critical workloads, especially in environments relying on high availability and performance monitoring on s390 systems. Although the vulnerability does not directly lead to privilege escalation or data leakage, the instability could indirectly affect confidentiality and integrity by causing unexpected system behavior or crashes. European organizations in sectors such as banking, government, and large-scale enterprise IT that utilize s390 mainframes for critical operations could face operational risks if this vulnerability is exploited or triggered unintentionally. Given the lack of known exploits, the immediate threat is low, but the potential for system disruption warrants timely patching.
Mitigation Recommendations
European organizations using Linux on s390 architectures should prioritize applying the official kernel patches that address this vulnerability by correctly checking the PMU_F_RESERVED bit before accessing sample data buffers during CPU hotplug events. System administrators should audit their kernel versions against the affected commit hashes and upgrade to patched versions as soon as they become available. Additionally, organizations should implement robust monitoring of kernel logs and performance monitoring subsystems to detect anomalies related to CPU hotplug events or PMU sampling. Testing kernel updates in staging environments that replicate production s390 workloads is recommended to ensure stability before deployment. Where possible, limiting CPU hotplug operations during critical performance monitoring activities can reduce the risk of triggering the vulnerability. Finally, maintaining up-to-date backups and recovery procedures for s390 systems will help mitigate the impact of any unexpected system crashes.
Affected Countries
Germany, United Kingdom, France, Netherlands, Italy, Switzerland
CVE-2024-57849: Vulnerability in Linux Linux
Description
In the Linux kernel, the following vulnerability has been resolved: s390/cpum_sf: Handle CPU hotplug remove during sampling CPU hotplug remove handling triggers the following function call sequence: CPUHP_AP_PERF_S390_SF_ONLINE --> s390_pmu_sf_offline_cpu() ... CPUHP_AP_PERF_ONLINE --> perf_event_exit_cpu() The s390 CPUMF sampling CPU hotplug handler invokes: s390_pmu_sf_offline_cpu() +--> cpusf_pmu_setup() +--> setup_pmc_cpu() +--> deallocate_buffers() This function de-allocates all sampling data buffers (SDBs) allocated for that CPU at event initialization. It also clears the PMU_F_RESERVED bit. The CPU is gone and can not be sampled. With the event still being active on the removed CPU, the CPU event hotplug support in kernel performance subsystem triggers the following function calls on the removed CPU: perf_event_exit_cpu() +--> perf_event_exit_cpu_context() +--> __perf_event_exit_context() +--> __perf_remove_from_context() +--> event_sched_out() +--> cpumsf_pmu_del() +--> cpumsf_pmu_stop() +--> hw_perf_event_update() to stop and remove the event. During removal of the event, the sampling device driver tries to read out the remaining samples from the sample data buffers (SDBs). But they have already been freed (and may have been re-assigned). This may lead to a use after free situation in which case the samples are most likely invalid. In the best case the memory has not been reassigned and still contains valid data. Remedy this situation and check if the CPU is still in reserved state (bit PMU_F_RESERVED set). In this case the SDBs have not been released an contain valid data. This is always the case when the event is removed (and no CPU hotplug off occured). If the PMU_F_RESERVED bit is not set, the SDB buffers are gone.
AI-Powered Analysis
Technical Analysis
CVE-2024-57849 is a vulnerability identified in the Linux kernel specifically affecting the s390 architecture's CPU sampling functionality during CPU hotplug events. The issue arises when a CPU is removed (hotplugged off) while a performance monitoring event is still active on that CPU. The kernel's performance monitoring unit (PMU) sampling driver for s390 CPUs deallocates the sample data buffers (SDBs) associated with the CPU during the CPU hotplug removal process. However, the event removal sequence subsequently attempts to read from these buffers, which have already been freed. This leads to a use-after-free condition where the driver may access invalid or reallocated memory, potentially causing data corruption or kernel instability. The root cause is that the kernel does not properly check whether the CPU's PMU sampling buffers are still reserved before attempting to read from them during event removal. The fix involves verifying the PMU_F_RESERVED bit to confirm if the buffers are still valid before accessing them. If the bit is not set, the buffers have been released and should not be accessed. This vulnerability is specific to the s390 architecture's CPU sampling subsystem and involves kernel internal handling of CPU hotplug events and performance monitoring. No known exploits are reported in the wild, and the vulnerability was published on January 11, 2025. The affected versions are identified by a specific commit hash, indicating a narrow scope tied to particular kernel builds.
Potential Impact
For European organizations, the impact of CVE-2024-57849 depends largely on their use of Linux systems running on IBM s390 mainframe architectures, which are less common than x86 or ARM architectures but are used in certain enterprise and financial sectors. The vulnerability could lead to kernel crashes or instability due to use-after-free memory access during CPU hotplug events, potentially causing denial of service or system outages. This could disrupt critical workloads, especially in environments relying on high availability and performance monitoring on s390 systems. Although the vulnerability does not directly lead to privilege escalation or data leakage, the instability could indirectly affect confidentiality and integrity by causing unexpected system behavior or crashes. European organizations in sectors such as banking, government, and large-scale enterprise IT that utilize s390 mainframes for critical operations could face operational risks if this vulnerability is exploited or triggered unintentionally. Given the lack of known exploits, the immediate threat is low, but the potential for system disruption warrants timely patching.
Mitigation Recommendations
European organizations using Linux on s390 architectures should prioritize applying the official kernel patches that address this vulnerability by correctly checking the PMU_F_RESERVED bit before accessing sample data buffers during CPU hotplug events. System administrators should audit their kernel versions against the affected commit hashes and upgrade to patched versions as soon as they become available. Additionally, organizations should implement robust monitoring of kernel logs and performance monitoring subsystems to detect anomalies related to CPU hotplug events or PMU sampling. Testing kernel updates in staging environments that replicate production s390 workloads is recommended to ensure stability before deployment. Where possible, limiting CPU hotplug operations during critical performance monitoring activities can reduce the risk of triggering the vulnerability. Finally, maintaining up-to-date backups and recovery procedures for s390 systems will help mitigate the impact of any unexpected system crashes.
Affected Countries
For access to advanced analysis and higher rate limits, contact root@offseq.com
Technical Details
- Data Version
- 5.1
- Assigner Short Name
- Linux
- Date Reserved
- 2025-01-11T12:33:33.699Z
- Cisa Enriched
- false
- Cvss Version
- null
- State
- PUBLISHED
Threat ID: 682d9822c4522896dcbde8dd
Added to database: 5/21/2025, 9:08:50 AM
Last enriched: 6/28/2025, 8:25:22 AM
Last updated: 8/4/2025, 6:58:30 AM
Views: 14
Related Threats
CVE-2025-3892: CWE-250: Execution with Unnecessary Privileges in Axis Communications AB AXIS OS
MediumCVE-2025-30027: CWE-1287: Improper Validation of Specified Type of Input in Axis Communications AB AXIS OS
MediumCVE-2025-7622: CWE-918: Server-Side Request Forgery (SSRF) in Axis Communications AB AXIS Camera Station Pro
MediumCVE-2025-8314: CWE-79 Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in emarket-design Project Management, Bug and Issue Tracking Plugin – Software Issue Manager
MediumCVE-2025-8059: CWE-862 Missing Authorization in bplugins B Blocks – The ultimate block collection
CriticalActions
Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.
External Links
Need enhanced features?
Contact root@offseq.com for Pro access with improved analysis and higher rate limits.