Security Vulnerability Report
中文
CVE-2025-54331 CVSS 5.3 MEDIUM

CVE-2025-54331

Published: 2025-11-04 17:16:23
Last Modified: 2025-11-07 12:56:30

Description

An issue was discovered in NPU in Samsung Mobile Processor Exynos 1380 through July 2025. There is an Untrusted Pointer Dereference of src_hdr in the copy_ncp_header function.

CVSS Details

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

Configurations (Affected Products)

cpe:2.3:o:samsung:exynos_1380_firmware:*:*:*:*:*:*:*:* - VULNERABLE
cpe:2.3:h:samsung:exynos_1380:-:*:*:*:*:*:*:* - NOT VULNERABLE
Samsung Exynos 1380 (through July 2025)

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
// CVE-2025-54331 PoC - Untrusted Pointer Dereference in Exynos 1380 NPU // This PoC demonstrates the vulnerability in copy_ncp_header function #include <stdio.h> #include <stdlib.h> #include <string.h> // Simulated NCP header structure struct ncp_header { uint32_t magic; uint32_t size; uint32_t type; uint32_t flags; uint64_t src_hdr_ptr; // Untrusted pointer (vulnerable field) }; // Vulnerable function - copy_ncp_header int copy_ncp_header(struct ncp_header* hdr, void* dest) { // VULNERABILITY: No validation of src_hdr_ptr before dereferencing struct ncp_header* untrusted_src = (struct ncp_header*)hdr->src_hdr_ptr; // This dereference can access arbitrary memory memcpy(dest, untrusted_src, sizeof(struct ncp_header)); return 0; } // Exploit demonstration int exploit_npu() { struct ncp_header* malicious_hdr = malloc(sizeof(struct ncp_header)); // Set up malicious pointer to point to controlled memory malicious_hdr->magic = 0x4E435032; // 'NCP2' malicious_hdr->size = sizeof(struct ncp_header); malicious_hdr->type = 0x01; malicious_hdr->flags = 0x00; // Point to arbitrary kernel memory (for demonstration) malicious_hdr->src_hdr_ptr = 0xFFFFFF0000000000; // Invalid kernel address void* dest_buffer = malloc(256); // Trigger the vulnerability copy_ncp_header(malicious_hdr, dest_buffer); free(malicious_hdr); free(dest_buffer); return 0; } int main() { printf("CVE-2025-54331 PoC\n"); printf("Exploiting untrusted pointer dereference in Exynos 1380 NPU\n"); exploit_npu(); return 0; }

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2025-54331", "sourceIdentifier": "[email protected]", "published": "2025-11-04T17:16:22.740", "lastModified": "2025-11-07T12:56:30.490", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "An issue was discovered in NPU in Samsung Mobile Processor Exynos 1380 through July 2025. There is an Untrusted Pointer Dereference of src_hdr in the copy_ncp_header function."}], "metrics": {"cvssMetricV31": [{"source": "134c704f-9b21-4f2e-91b3-4a467353bcc0", "type": "Secondary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L", "baseScore": 5.3, "baseSeverity": "MEDIUM", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "NONE", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "NONE", "integrityImpact": "NONE", "availabilityImpact": "LOW"}, "exploitabilityScore": 3.9, "impactScore": 1.4}]}, "weaknesses": [{"source": "134c704f-9b21-4f2e-91b3-4a467353bcc0", "type": "Secondary", "description": [{"lang": "en", "value": "CWE-822"}]}], "configurations": [{"operator": "AND", "nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:o:samsung:exynos_1380_firmware:*:*:*:*:*:*:*:*", "versionEndIncluding": "2025-07", "matchCriteriaId": "8A422138-B9FF-406B-A358-783E427FBF51"}]}, {"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": false, "criteria": "cpe:2.3:h:samsung:exynos_1380:-:*:*:*:*:*:*:*", "matchCriteriaId": "61E72146-72FE-4B54-AB79-3C665E7F016C"}]}]}], "references": [{"url": "https://semiconductor.samsung.com/support/quality-support/product-security-updates/", "source": "[email protected]", "tags": ["Vendor Advisory"]}, {"url": "https://semiconductor.samsung.com/support/quality-support/product-security-updates/cve-2025-54331/", "source": "[email protected]", "tags": ["Vendor Advisory"]}]}}