🔍 CVE-2026-72043

7.1
CVSS Score
HIGH
2026-08-15
2026-08-17 06:18
✅ 완료

🇰🇷 한글 설명

LoongArch 아키텍처의 Linux 커널에서 하드웨어 페이지 테이블 워커(PTW) 사용 시 dirty page 추적 기능이 누락되는 취약점이 발견되었습니다. 이로 인해 fork() 또는 clone() 시 Copy-on-Write 과정에서 페이지의 수정 상태 정보가 유실되어, 데이터가 디스크에 저장되지 않고 메모리에서 해제되는 데이터 오염이 발생할 수 있습니다.

💡 쉬운 설명

컴퓨터가 메모리에 저장된 데이터가 변경되었는지 제대로 인식하지 못해, 변경된 내용을 저장하지 않고 그냥 지워버릴 수 있는 문제입니다. 이로 인해 중요한 데이터가 사라지거나 파일이 깨지는 현상이 발생할 수 있습니다.

🇺🇸 원문 (English)

In the Linux kernel, the following vulnerability has been resolved: LoongArch: Fix missing dirty page tracking in {pte,pmd}_wrprotect() When hardware page table walker (PTW) is enabled on LoongArch, the CPU may set _PAGE_DIRTY directly in the page table entry during a write TLB miss, without going through the software TLB store handler. The software TLB store handler (tlbex.S:254) sets both _PAGE_DIRTY and_PAGE_MODIFIED together: ori t0, t0, (_PAGE_VALID | _PAGE_DIRTY | _PAGE_MODIFIED) Since hardware PTW only sets _PAGE_DIRTY, the software-only bit, i.e. _PAGE_MODIFIED is left unchanged. This creates a window where a PTE has _PAGE_DIRTY set (hardware knows the page is dirty) but _PAGE_MODIFIED clear (software is unaware). When fork()/clone() triggers copy-on-write, __copy_present_ptes() calls pte_wrprotect(), which unconditionally clears both the _PAGE_WRITE and _PAGE_DIRTY bits: pte_val(pte) &= ~(_PAGE_WRITE | _PAGE_DIRTY); Since _PAGE_MODIFIED was never set, the dirtiness information is lost completely. Subsequently, when memory pressure triggers page reclaim, page_mkclean() / try_to_unmap() sees the page as clean (i.e. pte_dirty() returns false) and the page may be freed without writeback, causing data corruption. Fix this by propagating the _PAGE_DIRTY bit to the _PAGE_MODIFIED bit in both pte_wrprotect() and pmd_wrprotect() before clearing writeable bits: if (pte_val(pte) & _PAGE_DIRTY) pte_val(pte) |= _PAGE_MODIFIED; The pmd_wrprotect() fix handles the CONFIG_TRANSPARENT_HUGEPAGE case, where pmd entries need the same treatment. This ensures the software dirty tracking bit (checked by pte_dirty() and pmd_dirty(), which read both the _PAGE_DIRTY and _PAGE_MODIFIED bits) is preserved across fork COW write-protection. The issue was found by the LTP madvise09 test case, which exercises page reclaim after "madvise(MADV_FREE), write and fork" operation sequence on private anonymous mappings.

📍 영향받는 시스템

LoongArch 아키텍처를 사용하는 Linux 커널 시스템

⚔️ 공격 벡터

특정 메모리 관리 시퀀스(madvise, write, fork)를 유도하여 데이터 무결성을 파괴하는 방식

🛡️ 대응 방법

LoongArch의 pte_wrprotect() 및 pmd_wrprotect() 함수에 _PAGE_DIRTY 비트를 _PAGE_MODIFIED 비트로 전파하는 커널 패치를 적용해야 합니다.

🔧 검증 코드

출력 결과의 아키텍처가 loongarch64인지 확인하고, 해당 취약점이 수정된 최신 커널 버전인지 확인합니다.

Shell / Script
uname -m && uname -r

📊 CVSS Vector String

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

💻 영향받는 소프트웨어

Linux Kernel