The llama.cpp project released version b11000, which addresses a critical security vulnerability in the RPC server. The fix resolves a use-after-free bug that allowed unauthenticated remote clients to achieve remote code execution by manipulating cached compute graphs.

  • A previous implementation cached compute graphs per device to avoid resending tensor data during GRAPH_RECOMPUTE operations.
  • These cached nodes held direct pointers to backend buffers; if a buffer was freed via FREE_BUFFER, subsequent re-execution accessed dangling pointers.
  • Attackers could reshape memory chunks via ALLOC_BUFFER and SET_TENSOR commands to leak libc addresses and hijack the buffer interface vtable.
  • The patch discards all cached graphs in free_buffer(), causing the client to fall back to GRAPH_COMPUTE on the next call.

This update prevents remote code execution exploits targeting the llama.cpp RPC server without requiring any protocol or API changes.