[all-commits] [llvm/llvm-project] ebb9a7: [clang][modules] Fix UAF in `InProcessModuleCache`...

Jan Svoboda via All-commits all-commits at lists.llvm.org
Wed May 6 13:41:42 PDT 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: ebb9a79cd370cd784f7e456914c4ade8c5c4d9fd
      https://github.com/llvm/llvm-project/commit/ebb9a79cd370cd784f7e456914c4ade8c5c4d9fd
  Author: Jan Svoboda <jan_svoboda at apple.com>
  Date:   2026-05-06 (Wed, 06 May 2026)

  Changed paths:
    M clang/include/clang/DependencyScanning/InProcessModuleCache.h
    M clang/lib/DependencyScanning/InProcessModuleCache.cpp
    M clang/unittests/DependencyScanning/CMakeLists.txt
    A clang/unittests/DependencyScanning/InProcessModuleCacheTest.cpp

  Log Message:
  -----------
  [clang][modules] Fix UAF in `InProcessModuleCache` (#196117)

Writing to the module cache would invalidate the read buffer. If the
timing works out just right, this is a use-after-free bug. This PR
prevents that situation by using two buffers in the module cache entry,
and adds a unit test that would previously fail under address sanitizer.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list