Gửi #1050821: SqueezeAILab SqueezeLLM main Out-of-bounds writethông tin

tiêu đềSqueezeAILab SqueezeLLM main Out-of-bounds write
Mô tảSqueezeLLM's dense-and-sparse CUDA matvec kernel writes out of bounds when it processes a crafted checkpoint. A SqueezeLLM checkpoint ships a full_row_indices int32 buffer of shape (topX,) (topX defaults to num_dense_channels = 10), loaded verbatim as a registered buffer. The kernel vecquant4matmul_spmv_hybrid_nuq_perchannel performs atomicAdd(&mul[full_row_indices[col]], value) using the checkpoint's index value with no bound check; the only guard in the kernel (threadIdx.x < width) bounds the thread, not the index. load_state_dict shape-checks that topX matches but never validates the index values, and loading uses torch.load, which on modern torch (>= 2.6, weights_only=True by default; the witness ran torch 2.13) loads a plain int32 tensor as data, so the issue is a genuine memory-safety bug and not merely subsumed by pickle deserialization. A full_row_indices value outside the output-row range causes an out-of-bounds GPU write via atomicAdd into adjacent memory, a memory-corruption primitive. Confirmed on an NVIDIA A100 with compute-sanitizer (control clean, crafted index -> out-of-bounds write). Requires loading and running an untrusted checkpoint; not reachable with a legitimate model. A secondary out-of-bounds read exists in the same kernel's CSR handling (SPMV_ATOMIC, unchecked rows/cols). Fix: bound full_row_indices (and the CSR row/col indices) against the output row count at load and/or in the kernel.
Nguồn⚠️ https://github.com/SqueezeAILab/SqueezeLLM/issues/77
Người dùng
 m00dy (UID 97162)
Đệ trình21/10/2026 23:17 (cách đây 1 tháng)
Kiểm duyệt20/11/2026 08:23 (29 days later)
Trạng tháiđược chấp nhận
Mục VulDB441203 [SqueezeAILab SqueezeLLM đến a5fd71f353bf569feb7b55737c1c1493e78e8f31 CUDA Matvec Kernel quant_cuda_kernel.cu vecquant4matmul_spmv_hybrid_nuq_perchannel full_row_indices tràn bộ đệm]
điểm20

Do you need the next level of professionalism?

Upgrade your account now!