[all-commits] [llvm/llvm-project] 34cccd: [BitcodeReader] Validate Strtab before accessing.

Florian Hahn via All-commits all-commits at lists.llvm.org
Tue Jun 22 06:53:51 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 34cccdaed7e7952a9191231ffa62b1b22eac35c8
      https://github.com/llvm/llvm-project/commit/34cccdaed7e7952a9191231ffa62b1b22eac35c8
  Author: Florian Hahn <flo at fhahn.com>
  Date:   2021-06-22 (Tue, 22 Jun 2021)

  Changed paths:
    M llvm/lib/Bitcode/Reader/BitcodeReader.cpp
    A llvm/test/Bitcode/invalid-record-strtab.ll
    A llvm/test/Bitcode/invalid-record-strtab.ll.bc

  Log Message:
  -----------
  [BitcodeReader] Validate Strtab before accessing.

This fixes a crash with invalid bitcode files that have records
referencing names in Strtab, but Strtab is not present or the index is
out-of-bounds.

This fixes the following clusterfuzz issue:
https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=29895

Reviewed By: arsenm

Differential Revision: https://reviews.llvm.org/D95554




More information about the All-commits mailing list