Security Vulnerability Report
中文
CVE-2023-53589 CVSS 5.5 MEDIUM

CVE-2023-53589

Published: 2025-10-04 16:15:55
Last Modified: 2026-03-21 00:47:00
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67

Description

In the Linux kernel, the following vulnerability has been resolved: wifi: iwlwifi: mvm: don't trust firmware n_channels If the firmware sends us a corrupted MCC response with n_channels much larger than the command response can be, we might copy far too much (uninitialized) memory and even crash if the n_channels is large enough to make it run out of the one page allocated for the FW response. Fix that by checking the lengths. Doing a < comparison would be sufficient, but the firmware should be doing it correctly, so check more strictly.

CVSS Details

CVSS Score
5.5
Severity
MEDIUM
CVSS Vector
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H

Configurations (Affected Products)

cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* - VULNERABLE
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* - VULNERABLE
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* - VULNERABLE
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* - VULNERABLE
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* - VULNERABLE
Linux Kernel < 6.5 (受影响的稳定版本)
Linux Kernel 6.5.x 系列
Linux Kernel 6.4.x 系列
Linux Kernel 6.1.x LTS 系列
Linux Kernel 5.15.x LTS 系列
Linux Kernel 5.10.x LTS 系列
Linux Kernel 5.4.x LTS 系列

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
// CVE-2023-53589 PoC - Conceptual exploit for iwlwifi n_channels validation bypass // This vulnerability requires local access and involves crafting malicious firmware responses // Note: Actual exploitation requires modifying firmware or using a compromised wireless device #include <stdio.h> #include <stdlib.h> #include <string.h> #include <stdint.h> // Simulated structures based on iwlwifi mvm MCC response #define MAX_CHANNELS 50 // Actual maximum channels in command response #define PAGE_SIZE 4096 // Simulated MCC response header from firmware struct iwl_mcc_update_resp { uint32_t n_channels; // Number of channels (vulnerable field) uint32_t mcc; // Mobile country code uint16_t channel_data[]; // Channel information array }; // Simulated command response structure struct iwl_mcc_update_cmd { uint32_t n_channels; uint32_t mcc; uint16_t channels[MAX_CHANNELS]; // Fixed-size array }; /* * Vulnerable function simulation - does NOT validate n_channels * In the real kernel, this would be in drivers/net/wireless/intel/iwlwifi/mvm/mcc.c */ void vulnerable_mcc_handler(uint8_t *fw_response, size_t resp_size) { struct iwl_mcc_update_resp *resp = (struct iwl_mcc_update_resp *)fw_response; struct iwl_mcc_update_cmd cmd; // Vulnerable: trusts firmware's n_channels without validation printf("Firmware reports n_channels: %u\n", resp->n_channels); // This memcpy could read beyond allocated buffer if n_channels is corrupted size_t copy_size = resp->n_channels * sizeof(uint16_t); if (copy_size > PAGE_SIZE) { printf("[CRASH] n_channels=%u causes out-of-bounds access!\n", resp->n_channels); printf("[CRASH] Attempting to copy %zu bytes, page only has %d bytes\n", copy_size, PAGE_SIZE); // In kernel: this would cause a page fault / kernel panic return; } memcpy(cmd.channels, resp->channel_data, copy_size); printf("Copied %zu bytes of channel data\n", copy_size); } /* * Fixed function - validates n_channels strictly */ void fixed_mcc_handler(uint8_t *fw_response, size_t resp_size) { struct iwl_mcc_update_resp *resp = (struct iwl_mcc_update_resp *)fw_response; struct iwl_mcc_update_cmd cmd; // Fixed: strict validation of n_channels if (resp->n_channels != MAX_CHANNELS) { printf("[BLOCKED] Invalid n_channels=%u, expected %d\n", resp->n_channels, MAX_CHANNELS); return; } memcpy(cmd.channels, resp->channel_data, resp->n_channels * sizeof(uint16_t)); printf("Successfully processed MCC response\n"); } int main() { // Simulate a corrupted firmware response with oversized n_channels size_t fake_resp_size = sizeof(struct iwl_mcc_update_resp) + 10 * sizeof(uint16_t); uint8_t *fake_response = calloc(1, fake_resp_size); struct iwl_mcc_update_resp *resp = (struct iwl_mcc_update_resp *)fake_response; // Set n_channels to a value much larger than actual data (simulating corruption) resp->n_channels = 10000; // Way more than MAX_CHANNELS (50) printf("=== Testing Vulnerable Handler ===\n"); vulnerable_mcc_handler(fake_response, fake_resp_size); printf("\n=== Testing Fixed Handler ===\n"); fixed_mcc_handler(fake_response, fake_resp_size); free(fake_response); return 0; }

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2023-53589", "sourceIdentifier": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "published": "2025-10-04T16:15:55.313", "lastModified": "2026-03-21T00:46:59.790", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nwifi: iwlwifi: mvm: don't trust firmware n_channels\n\nIf the firmware sends us a corrupted MCC response with\nn_channels much larger than the command response can be,\nwe might copy far too much (uninitialized) memory and\neven crash if the n_channels is large enough to make it\nrun out of the one page allocated for the FW response.\n\nFix that by checking the lengths. Doing a < comparison\nwould be sufficient, but the firmware should be doing\nit correctly, so check more strictly."}], "metrics": {"cvssMetricV31": [{"source": "[email protected]", "type": "Primary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H", "baseScore": 5.5, "baseSeverity": "MEDIUM", "attackVector": "LOCAL", "attackComplexity": "LOW", "privilegesRequired": "LOW", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "NONE", "integrityImpact": "NONE", "availabilityImpact": "HIGH"}, "exploitabilityScore": 1.8, "impactScore": 3.6}]}, "weaknesses": [{"source": "[email protected]", "type": "Primary", "description": [{"lang": "en", "value": "NVD-CWE-noinfo"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "4.1", "versionEndExcluding": "5.4.244", "matchCriteriaId": "BFF06705-5499-49B1-BD71-A9059267903F"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "5.5", "versionEndExcluding": "5.10.181", "matchCriteriaId": "F5B1726B-45AA-47F2-9261-6DC963E92248"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "5.11", "versionEndExcluding": "5.15.113", "matchCriteriaId": "F3D5E1B5-AB9D-4ECC-8F11-F3E1BF761E27"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "5.16", "versionEndExcluding": "6.1.30", "matchCriteriaId": "E9430E62-03EA-42E6-9E5E-BD1D5124D107"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "6.2", "versionEndExcluding": "6.3.4", "matchCriteriaId": "26C54BF0-3EED-46D4-92A7-5F07F658B49B"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:6.4:rc1:*:*:*:*:*:*", "matchCriteriaId": "38BC6744-7D25-4C02-9966-B224CD071D30"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:6.4:rc2:*:*:*:*:*:*", "matchCriteriaId": "76061B41-CAE9-4467-BEDE-0FFC7956F2A1"}]}]}], "references": [{"url": "https://git.kernel.org/stable/c/05ad5a4d421ce65652fcb24d46b7e273130240d6", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "tags": ["Patch"]}, {"url": "https://git.kernel.org/stable/c/557ba100d8cf3661ff8d71c0b4a2cba8db555ec2", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "tags": ["Patch"]}, {"url": "https://git.kernel.org/stable/c/682b6dc29d98e857e6ca4bbc077c7dc2899b7473", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "tags": ["Patch"]}, {"url": "https://git.kernel.org/stable/c/c176f03350954b795322de0bfe1d7b514db41f45", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "tags": ["Patch"]}, {"url": "https://git.kernel.org/stable/c/d0d39bed9e95f27a246be91c5929254ac043ed30", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "tags": ["Patch"]}, {"url": "https://git.kernel.org/stable/c/e519a404a5bbba37693cb10fa61794a5fce4fd9b", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "tags": ["Patch"]}]}}